diff options
Diffstat (limited to 'Master/texmf-dist/scripts/make4ht/mkutils.lua')
-rwxr-xr-x | Master/texmf-dist/scripts/make4ht/mkutils.lua | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/Master/texmf-dist/scripts/make4ht/mkutils.lua b/Master/texmf-dist/scripts/make4ht/mkutils.lua index ca9e2ff208a..e550ead9801 100755 --- a/Master/texmf-dist/scripts/make4ht/mkutils.lua +++ b/Master/texmf-dist/scripts/make4ht/mkutils.lua @@ -248,7 +248,7 @@ env.Make:add("htlatex",function(par) "\\HCode\\expandafter\\def\\csname tex4ht\\endcsname{#1,html}\\def".. "\\HCode####1{\\documentstyle[tex4ht,}\\@ifnextchar[{\\HCode}{".. "\\documentstyle[tex4ht]}}}\\makeatother\\HCode ${tex4ht_sty_par}.a.b.c.".. -"\\input ${input}'" +"\\input ${tex_file}'" if os.type == "windows" then command = command:gsub("'",'') end @@ -270,16 +270,20 @@ env.Make:add("htlatex",function(par) return 0 end ,{correct_exit=0}) -env.Make:add("tex4ht","tex4ht ${tex4ht_par} ${input}", nil, 1) -env.Make:add("t4ht","t4ht ${t4ht_par} ${input}.${ext}",{ext="dvi"},1) +env.Make:add("tex4ht","tex4ht ${tex4ht_par} \"${input}\"", nil, 1) +env.Make:add("t4ht","t4ht ${t4ht_par} \"${input}.${ext}\"",{ext="dvi"},1) function load_config(settings, config_name) local settings = settings or main_settings env.settings = settings env.mode = settings.mode - local config_name = config_name or "config.lua" + local config_name = kpse.find_file(config_name, 'texmfscripts') or config_name local f = io.open(config_name,"r") - if not f then return env, "Cannot open config file" end + if not f then + print("Cannot open config file", config_name) + return env + end + print("Using build file", config_name) local code = f:read("*all") local fn, msg = run(code,env) if not fn then print(msg) end |