summaryrefslogtreecommitdiff
path: root/sphinx/util/osutil.py
diff options
context:
space:
mode:
authorTakayuki SHIMIZUKAWA <shimizukawa@gmail.com>2016-02-09 16:57:34 +0900
committerTakayuki SHIMIZUKAWA <shimizukawa@gmail.com>2016-02-09 16:57:34 +0900
commit07c10e540fa218edb89cf02d532295fc8a3f1a95 (patch)
treee96efc271c1f558a83b4d73f87ac8e63f99ae7cb /sphinx/util/osutil.py
parenteb9c85f4ea70d78370d4c757df013046f85bfff6 (diff)
parent281bf2ae3accaa0052902ccf6d760b165b457812 (diff)
downloadsphinx-git-07c10e540fa218edb89cf02d532295fc8a3f1a95.tar.gz
Merge pull request #2074 from techtonik/patch-1
gettext: use canonical relative paths for .pot
Diffstat (limited to 'sphinx/util/osutil.py')
-rw-r--r--sphinx/util/osutil.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/sphinx/util/osutil.py b/sphinx/util/osutil.py
index e1d29a9d3..653530644 100644
--- a/sphinx/util/osutil.py
+++ b/sphinx/util/osutil.py
@@ -40,6 +40,11 @@ def os_path(canonicalpath):
return canonicalpath.replace(SEP, path.sep)
+def canon_path(nativepath):
+ """Return path in OS-independent form"""
+ return nativepath.replace(path.sep, SEP)
+
+
def relative_uri(base, to):
"""Return a relative URL from ``base`` to ``to``."""
if to.startswith(SEP):