Sfoglia il codice sorgente

Fix source code URL when addon path starts with root path (#546) (#1645)

Huidae Cho 3 anni fa
parent
commit
06c3840cda
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      utils/mkhtml.py

+ 1 - 1
utils/mkhtml.py

@@ -428,7 +428,7 @@ if not year:
 # check the names of scripts to assign the right folder
 # check the names of scripts to assign the right folder
 topdir = os.path.abspath(os.getenv("MODULE_TOPDIR"))
 topdir = os.path.abspath(os.getenv("MODULE_TOPDIR"))
 curdir = os.path.abspath(os.path.curdir)
 curdir = os.path.abspath(os.path.curdir)
-if curdir.startswith(topdir):
+if curdir.startswith(topdir + os.path.sep):
     source_url = trunk_url
     source_url = trunk_url
     pgmdir = curdir.replace(topdir, "").lstrip(os.path.sep)
     pgmdir = curdir.replace(topdir, "").lstrip(os.path.sep)
 else:
 else: