Fix #6813: An orphan warning is emitted for included document on Windows

This commit is contained in:
Takeshi KOMIYA committed 2019-11-16 23:14:25 +09:00
1 parent 7d0aa9594d
commit 155f4b0d00
2 files changed
+5

No files matched your search

+3
View File
@@ -59,6 +59,9 @@ Bugs fixed
code-block long enough not to fit on one page
* #6809: LaTeX: code-block in a danger type admonition can easily spill over
bottom of page
* #6813: An orphan warning is emitted for included document on Windows. Thanks
to @drillan
Testing
--------
+2
View File
@@ -13,6 +13,7 @@ import os
from sphinx.locale import __
from sphinx.util import get_matching_files
from sphinx.util import logging
from sphinx.util import path_stabilize
from sphinx.util.matching import compile_matchers
from sphinx.util.osutil import SEP, relpath
@@ -71,6 +72,7 @@ class Project:
filename = relpath(filename, self.srcdir)
for suffix in self.source_suffix:
if filename.endswith(suffix):
filename = path_stabilize(filename)
return filename[:-len(suffix)]
# the file does not have docname