]=])
list={}
n=tonumber(edcb.GetPrivateProfile('SET','RecFolderNum',0,'Common.ini'))
if n<=0 then
--録画保存フォルダが未設定のときは設定関係保存フォルダになる
list[1]=edcb.GetPrivateProfile('SET','DataSavePath','','Common.ini')
if list[1]=='' then
list[1]=edcb.GetPrivateProfile('SET','ModulePath','','Common.ini')..'\\Setting'
end
end
for i=0,n-1 do
list[#list+1]=edcb.GetPrivateProfile('SET','RecFolderPath'..i,'','Common.ini')
end
checked={}
for i,v in ipairs(list) do
v=v:match('^%a:\\')
if v and not checked[v:upper()] then
checked[v:upper()]=true
free=nil
f=edcb.io.popen('fsutil volume diskfree '..v)
if f then
free,total,avail=f:read('*a'):match(':%s*(%d+).*:%s*(%d+).*:%s*(%d+)')
f:close()
end
ct:Append('
'..v..'
'..(free and
('%.3f GB (avail: %.3f GB) / %.3f GB'):format(free/1024/1024/1024,avail/1024/1024/1024,total/1024/1024/1024) or '不明')..'
\n')
end
end
ct:Append([=[
]=])
ct:Finish()
mg.write(ct:Pop(Response(200,'text/html','utf-8',ct.len)..(ct.gzip and 'Content-Encoding: gzip\r\n' or '')..'\r\n'))