local fs = require("autosway.fs")
local file = fs.create("hello.txt")
file:write("Hello, world!")
file:flush()
local function recursive(path)
local dir = fs.read_dir(path)
local entry = dir:next()
while entry ~= nil do
print(entry:path())
if entry:metadata():is_dir() then
recursive(entry:path())
end
entry = dir:next()
end
end
recursive(".")
fs.remove("hello.txt")