From b566b93ebf0c666f8307a6398cebc13eceb23057 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Elan=20Ruusam=C3=A4e?= Date: Sun, 10 Feb 2008 12:59:47 +0000 Subject: [PATCH] - verbose shells adding - arg[2] is integer not string (!?) in lua Changed files: rpm.macros -> 1.429 --- rpm.macros | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/rpm.macros b/rpm.macros index 5a97446..7d72f17 100644 --- a/rpm.macros +++ b/rpm.macros @@ -1414,13 +1414,14 @@ if f then\ end\ for _, s in ipairs({%{expand:%%__lua_split %*}}) do\ if not t[s] then\ + print("Adding "..s.." to /etc/shells")\ f = io.open("/etc/shells", "a"); f:write(s.."\\n"); f:close()\ end\ end\ %{nil} %remove_etc_shells(p) %{-p:}\ -%{-p:if arg[2] == "0" then}\ +%{-p:if arg[2] == 0 then}\ t = {}\ f = io.open("/etc/shells", "r")\ if f then\ @@ -1428,6 +1429,7 @@ end\ f:close()\ end\ for _, l in pairs({%{expand:%%__lua_split %*}}) do\ + print("Removing "..l.." from /etc/shells")\ t[l] = nil\ end\ s=""\ -- 2.43.0