diff options
author | Adrian C. (anrxc) <anrxc@sysphere.org> | 2009-10-05 00:10:47 +0200 |
---|---|---|
committer | Adrian C. (anrxc) <anrxc@sysphere.org> | 2009-10-05 00:13:38 +0200 |
commit | d81eed6d310bce28b3709980d80c433a04eefaae (patch) | |
tree | 3ab65939b04a86d22e39ad6a4a5ac3ab122257b8 /dio.lua | |
parent | c2b68ad3e78e366e611600f54dcfa8d760ed026f (diff) | |
download | vicious-legacy-d81eed6d310bce28b3709980d80c433a04eefaae.tar.xz |
Lots of coding style changes
Diffstat (limited to 'dio.lua')
-rw-r--r-- | dio.lua | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -10,6 +10,10 @@ local io = { open = io.open } local setmetatable = setmetatable local math = { floor = math.floor } local table = { insert = table.insert } +local string = { + match = string.match, + gmatch = string.gmatch +} -- }}} @@ -28,14 +32,14 @@ local function worker(format, disk) local disk_lines = {} for line in f:lines() do - if line:match("("..disk..")%s") then + if string.match(line, "("..disk..")%s") then -- Todo: find a way to do this - --for stat in line:gmatch("%s([%d]+)") do + --for stat in string.gmatch(line, "%s([%d]+)") do -- table.insert(disk_lines, stat) --end -- -- Skip first two matches - local stat = line:gmatch("%s([%d]+)") + local stat = string.gmatch(line, "%s([%d]+)") stat() stat() -- Store the rest |