From cf42445dd5dce09224ee1bfa28f2925ce50d7eeb Mon Sep 17 00:00:00 2001 From: ruki Date: Sat, 27 Apr 2024 00:28:45 +0800 Subject: [PATCH] improve modulename --- xmake/plugins/show/lists/apis.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xmake/plugins/show/lists/apis.lua b/xmake/plugins/show/lists/apis.lua index f42f4b8399b..6e74bb6a82e 100644 --- a/xmake/plugins/show/lists/apis.lua +++ b/xmake/plugins/show/lists/apis.lua @@ -282,7 +282,7 @@ function script_extension_module_apis() if path.filename(modulename) == "main.lua" then modulename = path.directory(modulename) end - modulename = modulename:gsub("/", "."):gsub("%.lua", "") + modulename = modulename:gsub("[\\/]", "."):gsub("%.lua", "") local instance = import(modulename, {try = true, anonymous = true}) if instance then if _is_callable(instance) then