[latex3-commits] [git/LaTeX3-latex3-luaotfload] dev: Added missing local and stylistic changes (9e0d73e)

Marcel Fabian Krüger tex at 2krueger.de
Fri Oct 9 11:48:57 CEST 2020


Repository : https://github.com/latex3/luaotfload
On branch  : dev
Link       : https://github.com/latex3/luaotfload/commit/9e0d73e8fef63ab9fe11e245d31f0570a73c73bb

>---------------------------------------------------------------

commit 9e0d73e8fef63ab9fe11e245d31f0570a73c73bb
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date:   Fri Oct 9 11:48:57 2020 +0200

    Added missing local and stylistic changes


>---------------------------------------------------------------

9e0d73e8fef63ab9fe11e245d31f0570a73c73bb
 src/luaotfload-database.lua | 19 ++++++++++---------
 1 file changed, 10 insertions(+), 9 deletions(-)

diff --git a/src/luaotfload-database.lua b/src/luaotfload-database.lua
index 76d5690..c44d3b4 100644
--- a/src/luaotfload-database.lua
+++ b/src/luaotfload-database.lua
@@ -2357,18 +2357,19 @@ local function collect_font_filenames_texmf ()
         end
     end
 
-    local kpseshow_expanded_path = function (file_type) return kpse.expand_path (kpse.show_path (file_type)) end
+    local show_path = kpse.show_path
 
-    fontdirs = kpseshow_expanded_path "opentype fonts"
-    fontdirs = fontdirs .. path_separator .. kpseshow_expanded_path "truetype fonts"
-    fontdirs = fontdirs .. path_separator .. kpseshow_expanded_path "type1 fonts"
-    fontdirs = fontdirs .. path_separator .. kpseshow_expanded_path "afm"
-
-    fontdirs  = filesplitpath (fontdirs)
-    if not fontdirs then
-        return { }
+    local function expanded_path (file_type)
+        return kpseexpand_path (show_path (file_type))
     end
 
+    local fontdirs = expanded_path "opentype fonts"
+    fontdirs = fontdirs .. path_separator .. expanded_path "truetype fonts"
+    fontdirs = fontdirs .. path_separator .. expanded_path "type1 fonts"
+    fontdirs = fontdirs .. path_separator .. expanded_path "afm"
+
+    fontdirs = filesplitpath (fontdirs) or { }
+
     local tasks = filter_out_pwd (fontdirs)
     logreport ("both", 3, "db",
                "Initiating scan of %d directories.", #tasks)





More information about the latex3-commits mailing list.