diff options
Diffstat (limited to 'Server/Plugins/APIDump/main_APIDump.lua')
-rw-r--r-- | Server/Plugins/APIDump/main_APIDump.lua | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Server/Plugins/APIDump/main_APIDump.lua b/Server/Plugins/APIDump/main_APIDump.lua index 735a6ec05..5d6f5255f 100644 --- a/Server/Plugins/APIDump/main_APIDump.lua +++ b/Server/Plugins/APIDump/main_APIDump.lua @@ -136,7 +136,7 @@ local function CreateAPITables() return res; end - for i, v in pairs(_G) do + for i, v in pairs(getmetatable(_G).__index) do if ( (v ~= _G) and -- don't want the global namespace (v ~= _G.packages) and -- don't want any packages @@ -1473,7 +1473,7 @@ end --- Returns the string with extra tabs and CR/LFs removed -local function CleanUpDescription(a_Desc) +function CleanUpDescription(a_Desc) -- Get rid of indent and newlines, normalize whitespace: local res = a_Desc:gsub("[\n\t]", "") res = a_Desc:gsub("%s%s+", " ") @@ -1858,6 +1858,9 @@ local function DumpApi() -- Dump all available API objects in format used by ZeroBraneStudio API descriptions: DumpAPIZBS(API) + -- Dump all available API objects in format used by Lua-Language-Server API descriptions: + DumpAPILLS(API); + -- Export the API in a format used by LuaCheck DumpLuaCheck(API) |