SPECS: pdksh.spec - tabs in lua scriptlets
glen
glen at pld-linux.org
Tue Oct 16 04:12:19 CEST 2007
Author: glen Date: Tue Oct 16 02:12:19 2007 GMT
Module: SPECS Tag: HEAD
---- Log message:
- tabs in lua scriptlets
---- Files affected:
SPECS:
pdksh.spec (1.115 -> 1.116)
---- Diffs:
================================================================
Index: SPECS/pdksh.spec
diff -u SPECS/pdksh.spec:1.115 SPECS/pdksh.spec:1.116
--- SPECS/pdksh.spec:1.115 Tue Oct 9 17:31:11 2007
+++ SPECS/pdksh.spec Tue Oct 16 04:12:14 2007
@@ -157,54 +157,54 @@
t = {}
f = io.open("/etc/shells", "r")
if f then
- for l in f:lines() do t[l]=l; end
- f:close()
+ for l in f:lines() do t[l]=l; end
+ f:close()
end
for _, s in ipairs({"/bin/ksh", "/bin/sh"}) do
- if not t[s] then
- f = io.open("/etc/shells", "a"); f:write(s.."\n"); f:close()
- end
+ if not t[s] then
+ f = io.open("/etc/shells", "a"); f:write(s.."\n"); f:close()
+ end
end
%preun -p <lua>
if arg[2] == "0" then
- f = io.open("/etc/shells", "r")
- if f then
- s=""
- for l in f:lines() do
- if not string.match(l,"^/bin/k?sh$") then
- s=s..l.."\n"
- end
- end
- f:close()
- io.open("/etc/shells", "w"):write(s)
- end
+ f = io.open("/etc/shells", "r")
+ if f then
+ s=""
+ for l in f:lines() do
+ if not string.match(l,"^/bin/k?sh$") then
+ s=s..l.."\n"
+ end
+ end
+ f:close()
+ io.open("/etc/shells", "w"):write(s)
+ end
end
%post static -p <lua>
t = {}
f = io.open("/etc/shells", "r")
if f then
- for l in f:lines() do t[l]=l; end
- f:close()
+ for l in f:lines() do t[l]=l; end
+ f:close()
end
if not t["/bin/ksh.static"] then
- f = io.open("/etc/shells", "a"); f:write("/bin/ksh.static\n"); f:close()
+ f = io.open("/etc/shells", "a"); f:write("/bin/ksh.static\n"); f:close()
end
%preun static -p <lua>
if arg[1] == "2" then
- f = io.open("/etc/shells", "r")
- if f then
- s=""
- for l in f:lines() do
- if not string.match(l,"^/bin/ksh\.static$") then
- s=s..l.."\n"
- end
- end
- f:close()
- io.open("/etc/shells", "w"):write(s)
- end
+ f = io.open("/etc/shells", "r")
+ if f then
+ s=""
+ for l in f:lines() do
+ if not string.match(l,"^/bin/ksh\.static$") then
+ s=s..l.."\n"
+ end
+ end
+ f:close()
+ io.open("/etc/shells", "w"):write(s)
+ end
end
%files
@@ -228,6 +228,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.116 2007/10/16 02:12:14 glen
+- tabs in lua scriptlets
+
Revision 1.115 2007/10/09 15:31:11 baggins
- s/enviroment/environment/
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/pdksh.spec?r1=1.115&r2=1.116&f=u
More information about the pld-cvs-commit
mailing list