summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorManuel Pégourié-Gonnard <mpg@elzevir.fr>2008-08-02 13:38:00 +0000
committerManuel Pégourié-Gonnard <mpg@elzevir.fr>2008-08-02 13:38:00 +0000
commit066bf9037acc2614e317dce5980e6be98d5c2cd2 (patch)
treee8996c8fa2a31b56bf722527edf0d0117a1e82c4 /Master
parentca6ca605b2b66f9de7d8c5b12d9c8f471888a7ff (diff)
fixing bug in ordering, using code_path to pad code too two digits
git-svn-id: svn://tug.org/texlive/trunk@10012 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rwxr-xr-xMaster/texmf/scripts/texlive/texdoc.tlu11
1 files changed, 9 insertions, 2 deletions
diff --git a/Master/texmf/scripts/texlive/texdoc.tlu b/Master/texmf/scripts/texlive/texdoc.tlu
index 584f22ce19e..ce1dc1d719e 100755
--- a/Master/texmf/scripts/texlive/texdoc.tlu
+++ b/Master/texmf/scripts/texlive/texdoc.tlu
@@ -131,13 +131,20 @@ function process_file (file, pathfile, code, pattern)
if string.find(pathfile, pattern, 1, no_regex) and is_good_ext (ext)
then
if base == pattern then
- table.insert(exact_docfiles, code..':'..pathfile)
+ table.insert(exact_docfiles, code_path (code, pathfile))
else
- table.insert(rel_docfiles, code..':'..pathfile)
+ table.insert(rel_docfiles, code_path (code, pathfile))
end
end
end
+-- encodes the base path on two digits and concatenate with filename
+-- see real_path() for decoding
+function code_path (code, file)
+ local padding = (code > 9) and '' or '0'
+ return padding..code..':'..file
+end
+
-- scan a tree
function scan_tree (code, path, pattern, recurse)
for file in lfs.dir(path) do