Usar $HOME

This commit is contained in:
Cat /dev/Nulo 2022-05-03 21:42:19 -03:00
parent e2b048151b
commit 10c3b635d0

View file

@ -26,7 +26,7 @@ local status = os.execute("mkdir -p ~/.cache/themer.lua/")
if not (status == 0) then return status end if not (status == 0) then return status end
function save_config(name, template, params) function save_config(name, template, params)
local file, err = io.open("/home/diablo/.cache/themer.lua/"..name, "w+") local file, err = io.open(os.getenv("HOME").."/.cache/themer.lua/"..name, "w+")
if not file then expect_nil(err) end if not file then expect_nil(err) end
file:write(templater(template, params)) file:write(templater(template, params))
file:close() file:close()