diff --git a/CHANGES b/CHANGES index 8ac51f522..561d0f45c 100644 --- a/CHANGES +++ b/CHANGES @@ -20,6 +20,7 @@ Bugs fixed * #1480, #2188: LaTeX: Support math in section titles * #2071: Fix same footnote in more than two section titles => LaTeX/PDF Bug * #2040: Fix UnicodeDecodeError in sphinx-apidoc when author contains non-ascii characters +* #2193: Fix shutil.SameFileError if source directory and destination directory are same Release 1.3.3 (released Dec 2, 2015) diff --git a/sphinx/cmdline.py b/sphinx/cmdline.py index e411836c3..e9d76bb83 100644 --- a/sphinx/cmdline.py +++ b/sphinx/cmdline.py @@ -144,6 +144,10 @@ def main(argv): file=sys.stderr) return 1 outdir = abspath(args[1]) + if srcdir == outdir: + print('Error: source directory and destination directory are same.', + file=sys.stderr) + return 1 except IndexError: parser.print_help() return 1