From bcc6ec770529a4d41680277be716861c5cd9eed3 Mon Sep 17 00:00:00 2001 From: dvs1 Date: Mon, 4 Nov 2024 15:54:24 +1000 Subject: Switch confFile to name, to be used more genericaly. --- PolygLua.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/PolygLua.lua b/PolygLua.lua index e4cf6db..77f01f4 100755 --- a/PolygLua.lua +++ b/PolygLua.lua @@ -100,7 +100,7 @@ _.usage = function(args, options, all) end end -_.parse = function(args, options, confFile) +_.parse = function(args, options, name) local o = nil local doIt = function(name, val, a, args, i) @@ -113,9 +113,9 @@ _.parse = function(args, options, confFile) return o end - if nil ~= confFile then + if nil ~= name then for i,v in ipairs{'/etc/', '~/.', './.'} do - local p = v .. confFile .. '.conf.lua' + local p = v .. name .. '.conf.lua' local h = io.open(p, 'r') if nil ~= h then D('Found configuration file '.. p) -- cgit v1.1