diff options
author | onefang | 2019-12-28 22:45:36 +1000 |
---|---|---|
committer | onefang | 2019-12-28 22:45:36 +1000 |
commit | cafd4c5d4ae2de4266026d44f9340fa3de2f2b40 (patch) | |
tree | 85d972bac4592596b38b7d63e94e557cf954fce1 /apt-panopticon-update-data.lua | |
parent | Tweak the dumpTable() arguments a little. (diff) | |
download | apt-panopticon-cafd4c5d4ae2de4266026d44f9340fa3de2f2b40.zip apt-panopticon-cafd4c5d4ae2de4266026d44f9340fa3de2f2b40.tar.gz apt-panopticon-cafd4c5d4ae2de4266026d44f9340fa3de2f2b40.tar.bz2 apt-panopticon-cafd4c5d4ae2de4266026d44f9340fa3de2f2b40.tar.xz |
Finish the executable refactor, by using it and removing the original.
Diffstat (limited to 'apt-panopticon-update-data.lua')
-rwxr-xr-x | apt-panopticon-update-data.lua | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/apt-panopticon-update-data.lua b/apt-panopticon-update-data.lua index a26b11b..8ab9254 100755 --- a/apt-panopticon-update-data.lua +++ b/apt-panopticon-update-data.lua | |||
@@ -106,9 +106,11 @@ local files = io.popen('ls -d1 results_*') | |||
106 | for l in files:lines() do | 106 | for l in files:lines() do |
107 | if ('results_old' ~= l) and ('.tar.xz' ~= l:sub(25, -1)) then | 107 | if ('results_old' ~= l) and ('.tar.xz' ~= l:sub(25, -1)) then |
108 | if APT.checkFile(l .. '/stamp') then | 108 | if APT.checkFile(l .. '/stamp') then |
109 | local status, whn = APT.execute('TZ="GMT" ls -d1 --time-style="+%s" ' .. l .. ' | cut -d " " -f 6-6') | 109 | -- local status, whn = APT.execute('TZ="GMT" ls -d1 --time-style="+%s" ' .. l .. ' | cut -d " " -f 6-6') |
110 | local whn = APT.exe('TZ="GMT" ls -d1 --time-style="+%s" ' .. l .. ' | cut -d " " -f 6-6'):Do() | ||
110 | whn = whn:sub(2, -2) | 111 | whn = whn:sub(2, -2) |
111 | local status, new = APT.execute('TZ="GMT" date -d "' .. whn:sub(9, 18) .. ' ' .. whn:sub(20, 21) .. ':' .. whn:sub(23, 24) .. '" "+%s"') | 112 | -- local status, new = APT.execute('TZ="GMT" date -d "' .. whn:sub(9, 18) .. ' ' .. whn:sub(20, 21) .. ':' .. whn:sub(23, 24) .. '" "+%s"') |
113 | local new = APT.exe('TZ="GMT" date -d "' .. whn:sub(9, 18) .. ' ' .. whn:sub(20, 21) .. ':' .. whn:sub(23, 24) .. '" "+%s"'):Do() | ||
112 | APT.now = tonumber("0" .. new:sub(2, -2)) | 114 | APT.now = tonumber("0" .. new:sub(2, -2)) |
113 | if 0 ~= APT.now then | 115 | if 0 ~= APT.now then |
114 | if APT.checkFile(l .. '/mirrors.lua') then | 116 | if APT.checkFile(l .. '/mirrors.lua') then |