Minetest-WorldEditAdditions/worldeditadditions_core/utils/io.lua
2022-09-18 16:45:08 +01:00

14 lines
364 B
Lua

local io = {
-- Ref https://minetest.gitlab.io/minetest/minetest-namespace-reference/#utilities
scandir = function(dirpath)
return minetest.get_dir_list(dirpath, nil)
end,
scandir_files = function(dirpath)
return minetest.get_dir_list(dirpath, false)
end,
scandir_dirs = function(dirpath)
return minetest.get_dir_list(dirpath, true)
end,
}
return io