From 9a6c8684ec9bfd7cc1febbe52c454937cd3f5570 Mon Sep 17 00:00:00 2001 From: Takuto Asakura Date: Sat, 10 Aug 2024 22:19:00 +0900 Subject: [PATCH] more w32_path for debug outputs --- script/texdoclib-config.tlu | 3 ++- script/texdoclib-search.tlu | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/script/texdoclib-config.tlu b/script/texdoclib-config.tlu index 881a556..44b42de 100644 --- a/script/texdoclib-config.tlu +++ b/script/texdoclib-config.tlu @@ -152,7 +152,8 @@ function M.set_config_element(key, value, context) -- special case: if we just set debug_list, print version info now if key == 'debug_list' then - dbg_print('version', '%s v%s', C.fullname, C.version) + local w32_path = import_function('util', 'w32_path') + dbg_print('version', '%s v%s', w32_path(C.fullname), C.version) end -- now tell what we have just done, for debugging diff --git a/script/texdoclib-search.tlu b/script/texdoclib-search.tlu index b560626..b44eeb5 100644 --- a/script/texdoclib-search.tlu +++ b/script/texdoclib-search.tlu @@ -359,6 +359,7 @@ init_texdocs_database = function() doc_roots = {} local kpse_texdocs = kpse.expand_var('$TEXDOCS') + local w32_path = texdoc.util.w32_path -- expand the path and turn it into a lua list local raw_doc_roots = kpse.expand_braces(kpse_texdocs):explode(C.kpse_sep) @@ -376,13 +377,13 @@ init_texdocs_database = function() local index_mandatory = (n == 1) dbg_print('texdocs', 'texdocs[%d] = %s (index_mandatory=%s, recursion_allowed=%s)', - i, path, tostring(index_mandatory), tostring(recursion_allowed)) + i, w32_path(path), tostring(index_mandatory), tostring(recursion_allowed)) -- decide if we should use a ls-R index, the filesystem, or do nothing local root, shift = lsr_root(path) if root and shift and recursion_allowed then dbg_print('texdocs', - 'texdocs[%d] using index: %s (shift=%s)', i, root, shift) + 'texdocs[%d] using index: %s (shift=%s)', i, w32_path(root), shift) db = init_lsr_db(root, shift) elseif not index_mandatory and lfs.isdir(path) then dbg_print('texdocs',