diff options
author | Adrian C. (anrxc) <anrxc@sysphere.org> | 2009-11-12 01:41:33 +0100 |
---|---|---|
committer | Adrian C. (anrxc) <anrxc@sysphere.org> | 2009-11-12 01:41:33 +0100 |
commit | 249294551e91b84a0c8bd81f128db8c749651677 (patch) | |
tree | bd0e55d7a987f91dee4acd434627fed7917fad02 | |
parent | f5b47dca8b5bb915f6e6dc17ea5852d099609889 (diff) | |
download | vicious-legacy-249294551e91b84a0c8bd81f128db8c749651677.tar.xz |
fs: minor coding style change
-rw-r--r-- | fs.lua | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -27,9 +27,8 @@ local function worker(format, nfs) for line in f:lines() do if not string.match(line, "^Filesystem.*") then - local size, used, avail, usep, mount = - -- Match all at once, including network file systems - string.match(line, "^[%w%p]+[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d]+)%%[%s]+([%w%p]+)$") + local size, used, avail, usep, mount = string.match(line, -- Match all (network file systems too) + "^[%w%p]+[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d]+)%%[%s]+([%w%p]+)$") fs_info["{"..mount.." size}"] = tonumber(size) fs_info["{"..mount.." used}"] = tonumber(used) |