From a38dcda19542af3e9d27e6792166a027e29a125b Mon Sep 17 00:00:00 2001 From: Elie Roux Date: Sun, 7 Apr 2013 19:50:05 +0200 Subject: Fixing character escaping errors Some syntax errors in Lua for character escaping were silently ignore by old versions of LuaTeX, but the new one raises errors. Maybe a side effect of Lua 5.2? --- otfl-basics-gen.lua | 2 +- otfl-font-nms.lua | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/otfl-basics-gen.lua b/otfl-basics-gen.lua index bdbc3cf..bfd81fd 100644 --- a/otfl-basics-gen.lua +++ b/otfl-basics-gen.lua @@ -85,7 +85,7 @@ local remapper = { } function resolvers.findfile(name,fileformat) - name = string.gsub(name,"\\","\/") + name = string.gsub(name,"\\","/") fileformat = fileformat and string.lower(fileformat) local found = kpse.find_file(name,(fileformat and fileformat ~= "" and (remapper[fileformat] or fileformat)) or file.extname(name,"tex")) if not found or found == "" then diff --git a/otfl-font-nms.lua b/otfl-font-nms.lua index 87f4987..094ebec 100644 --- a/otfl-font-nms.lua +++ b/otfl-font-nms.lua @@ -557,8 +557,8 @@ local function scan_texmf_fonts(fontnames, newfontnames) else logs.info("Scanning TEXMF and OS fonts...") end - local fontdirs = expandpath("$OPENTYPEFONTS"):gsub("^\.", "") - fontdirs = fontdirs .. expandpath("$TTFONTS"):gsub("^\.", "") + local fontdirs = expandpath("$OPENTYPEFONTS"):gsub("^%.", "") + fontdirs = fontdirs .. expandpath("$TTFONTS"):gsub("^%.", "") if not fontdirs:is_empty() then for _,d in next, splitpath(fontdirs) do scan_dir(d, fontnames, newfontnames, true) -- cgit v1.2.3