From a7590db7d9133793d951309cfd85cde114b13f4b Mon Sep 17 00:00:00 2001 From: Joshua Bronson Date: Tue, 11 Aug 2020 21:02:38 -0400 Subject: [PATCH] Document shutil.copytree now accepts dirs_exist_ok (#262) boltons' copytree is needed for Python < 3.8. --- boltons/fileutils.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/boltons/fileutils.py b/boltons/fileutils.py index 28ecadb..fbe0140 100644 --- a/boltons/fileutils.py +++ b/boltons/fileutils.py @@ -515,6 +515,9 @@ def copy_tree(src, dst, symlinks=False, ignore=None): raise an exception if part of the tree already exists. It achieves this by using :func:`mkdir_p`. + As of Python 3.8, you may pass :func:`shutil.copytree` the + `dirs_exist_ok=True` flag to achieve the same effect. + Args: src (str): Path of the source directory to copy. dst (str): Destination path. Existing directories accepted.