C7EHA774SZOZYAFWKAVLDYENLI36NWVXJLZV4QT4XJXOMTHXJTFQC
HNSIHMJEBLJ45E2ZOPX4JRKRIYVJBCRZQLDNIZKDTBOK7N6DTAVAC
3WL5OW24CZYD3Y3ZSN62HG6JUTHXIBWIJ7DBK6NHQOPMY2CI4XAQC
VDXOEDS757ISV5KM5AUFZDFH223CHQB4FK3TQOQ75CDDJAPLCFQQC
3QNOKBFMKBGXBVJIRHR2444JRRMBTABHE4674NR3DT67RRM2X6GAC
IDS27PX6ITX6XVQ7PAPNGQBQUHBSM4WY2TBI4PU37PCJBYTVJ6UAC
ED4Z6ORCADLWJPSZNKQVUF63NBKLQVE7UFMBTQAQA5O47X4NLFIAC
FQURPLDAJ23WHRCFKBL3UFDL2MAQIJ7NIOXS7H6MLOGLW2QB33UAC
LLQC2M2IMEJBJQXZTKC3OAKG5WKHSERXKAKCYHQRUZZD6CVRIHAQC
AQOJ62LNFASJ3VVCJEHWMLNPYHD4KPPE2QRILWRKC3BVJ5YSDO4AC
HKV72RZVJEOF5GCHCRKEBGC3FQN7AYETY7LKEJUXVIQAB4QPEPYQC
App.open_for_writing =
function(filename)
local result = nativefs.newFile(filename)
local ok, err = result:open('w')
if ok then
return result
else
return ok, err
end
end
end
end
App.read_file =
function(path)
if not is_absolute_path(path) then
return --[[status]] false, 'Please use an unambiguous absolute path.'
end
local f, err = App.open_for_reading(path)
if err then
return --[[status]] false, err
local contents = f:read()
f:close()
return contents
App.write_file =
function(path, contents)
if not is_absolute_path(path) then
return --[[status]] false, 'Please use an unambiguous absolute path.'
end
local f, err = App.open_for_writing(path)
if err then
return --[[status]] false, err
end
f:write(contents)
f:close()
return --[[status]] true
end