From 13527a38e8136bae83dc75f24e85f5fd45d4fbf0 Mon Sep 17 00:00:00 2001 From: "Adrian C. (anrxc)" Date: Thu, 27 Aug 2009 12:46:08 +0200 Subject: Match all punctuation chars in fs partitions and mount points. With some recent commits we are matching a good number of custom characters. Instead of waiting for another one that breaks it, just match all punctuation characters. The regexp is pretty big and some simplification is also welcomed. --- fs.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs.lua b/fs.lua index 73106b8..d5b0031 100644 --- a/fs.lua +++ b/fs.lua @@ -27,7 +27,7 @@ local function worker(format) -- table for each mount point with gmatch local size, used, avail, usep, mount = -- Instead match all at once, including network file systems - line:match("^[/%w:%.-]+[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d]+)%%[%s]+([/%w:%.-]+)$") + line:match("^[%w%p]+[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d%.]+)[%a]?[%s]+([%d]+)%%[%s]+([%w%p]+)$") fs_info["{"..mount.." size}"] = size fs_info["{"..mount.." used}"] = used -- cgit v1.2.3