diff options
author | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | 2010-01-05 19:31:07 +0000 |
---|---|---|
committer | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | 2010-01-05 19:31:07 +0000 |
commit | 15dac3ed537b65be8dcc04511e63e8c7517e74f5 (patch) | |
tree | 279b20a434999e6ed97bb066679fe156d7e895eb /Master/texmf/scripts/texdoc | |
parent | 70a04e55d9bcb2ced6c19414122f5d92123ecbcb (diff) |
New texdoc with easier zip support activation.
git-svn-id: svn://tug.org/texlive/trunk@16604 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf/scripts/texdoc')
-rw-r--r-- | Master/texmf/scripts/texdoc/config.tlu | 14 | ||||
-rw-r--r-- | Master/texmf/scripts/texdoc/constants.tlu | 18 | ||||
-rw-r--r-- | Master/texmf/scripts/texdoc/functions.tlu | 16 |
3 files changed, 13 insertions, 35 deletions
diff --git a/Master/texmf/scripts/texdoc/config.tlu b/Master/texmf/scripts/texdoc/config.tlu index dac13ef49a4..3ff14178f8c 100644 --- a/Master/texmf/scripts/texdoc/config.tlu +++ b/Master/texmf/scripts/texdoc/config.tlu @@ -483,15 +483,11 @@ function setup_config_from_defaults() -- must be set after mode! set_config_elt ('alias_switch', alias_from_mode(config.mode)) -- zip-related options - if C.support_zipped then - set_config_ls { - zipext_list = 'gz, bz2', - unzip_gz = 'gzip -d -c', - unzip_bz2 = 'bzip -d -c', - rm_file = 'rm -f', - rm_dir = 'rmdir' - } - end + set_config_ls { + zipext_list = '', + rm_file = 'rm -f', + rm_dir = 'rmdir', + } end -- the default value of config.alias_switch depends on the mode as follows diff --git a/Master/texmf/scripts/texdoc/constants.tlu b/Master/texmf/scripts/texdoc/constants.tlu index 2cbc99579df..b3c57b7be8c 100644 --- a/Master/texmf/scripts/texdoc/constants.tlu +++ b/Master/texmf/scripts/texdoc/constants.tlu @@ -15,7 +15,7 @@ load_env(L, { -- progname and version fullname = arg[0] progname = 'texdoc' -version = '0.61' +version = '0.62' -- make sure to update setup_config_from_cl() accordingly -- and set a default value in setup_config_from_defaults() if relevant @@ -88,22 +88,6 @@ known_debugs = { place_holder = '%%s' -- used for viewer commands --- zip/gz support --- --- optionally, texdoc can support compressed documentation, but this is --- system-dependant (commands for unzipping, temporary files, etc). --- Since TeX Live doesn't ship compressed documentation, and I'm too lazy to --- make zip support work reliably on all platforms, I don't turn into an --- official option. However, it should work on Unix platforms. --- --- If you enable zip support here, please check the configuration in config.tlu --- (look for support_zipped). The zip command should write the unzipped file to --- STDOUT. Check carefully that everything works as expected, since it got far --- less testing than the rest of texdoc. --- --- See also comments in texdoc.cnf about viewer settings. -support_zipped = false - -- make C a proxy to the local environment assert(next(C) == nil, 'Internal error: table of constants should be empty at this point') diff --git a/Master/texmf/scripts/texdoc/functions.tlu b/Master/texmf/scripts/texdoc/functions.tlu index 4db39c2482f..cff6e2aaeec 100644 --- a/Master/texmf/scripts/texdoc/functions.tlu +++ b/Master/texmf/scripts/texdoc/functions.tlu @@ -78,16 +78,14 @@ end end -- scope of active_debugs --- if zip is support and file is base..'.'..zip with zip in zipext_list, --- return base, zip -- otherwise, returns file, nil +-- if file is base..'.'..zip with zip in zipext_list, return: base, zip +-- otherwise, return: file, nil function parse_zip(file) - if C.support_zipped then - local zip - for _, zip in ipairs(config.zipext_list) do - local l = #zip + 1 - if string.sub(file, -l, -1) == '.'..zip then - return string.sub(file, 1, -l - 1), zip - end + local zip + for _, zip in ipairs(config.zipext_list) do + local l = #zip + 1 + if string.sub(file, -l, -1) == '.'..zip then + return string.sub(file, 1, -l - 1), zip end end return file, nil |