mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
add inverse of util.os_path for canonical path generation
This commit is contained in:
@@ -39,6 +39,10 @@ SEP = "/"
|
||||
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``."""
|
||||
|
||||
Reference in New Issue
Block a user