summaryrefslogtreecommitdiff
path: root/sphinx/builders/html.py
diff options
context:
space:
mode:
authorTakeshi KOMIYA <i.tkomiya@gmail.com>2019-11-17 14:24:04 +0900
committerTakeshi KOMIYA <i.tkomiya@gmail.com>2019-11-17 14:24:04 +0900
commit66448309413a56b9e38daa758a12a1e4f4556616 (patch)
treeadd850ce39f998d641c65d8497de7803bed024ac /sphinx/builders/html.py
parent05c31a03144633d097a695c531a4e54d097b1ba1 (diff)
parentfcdeafd56e67cc38dcd56862cc0ee6304178a3e8 (diff)
downloadsphinx-git-66448309413a56b9e38daa758a12a1e4f4556616.tar.gz
Merge branch '2.0'
Diffstat (limited to 'sphinx/builders/html.py')
-rw-r--r--sphinx/builders/html.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/sphinx/builders/html.py b/sphinx/builders/html.py
index e86958b48..50c38cdb2 100644
--- a/sphinx/builders/html.py
+++ b/sphinx/builders/html.py
@@ -1124,7 +1124,8 @@ def validate_html_extra_path(app: Sphinx, config: Config) -> None:
if not path.exists(extra_path):
logger.warning(__('html_extra_path entry %r does not exist'), entry)
config.html_extra_path.remove(entry)
- elif path.commonpath([app.outdir, extra_path]) == app.outdir:
+ elif (path.splitdrive(app.outdir)[0] == path.splitdrive(extra_path)[0] and
+ path.commonpath([app.outdir, extra_path]) == app.outdir):
logger.warning(__('html_extra_path entry %r is placed inside outdir'), entry)
config.html_extra_path.remove(entry)
@@ -1136,7 +1137,8 @@ def validate_html_static_path(app: Sphinx, config: Config) -> None:
if not path.exists(static_path):
logger.warning(__('html_static_path entry %r does not exist'), entry)
config.html_static_path.remove(entry)
- elif path.commonpath([app.outdir, static_path]) == app.outdir:
+ elif (path.splitdrive(app.outdir)[0] == path.splitdrive(static_path)[0] and
+ path.commonpath([app.outdir, static_path]) == app.outdir):
logger.warning(__('html_static_path entry %r is placed inside outdir'), entry)
config.html_static_path.remove(entry)