Sophie

Sophie

distrib > Scientific%20Linux > 5x > i386 > by-pkgid > b97cc630a62f26a4c7ed7a29fcec4ed2 > scriptlet

tcsh617-6.17-7.el5.i386.rpm

POSTIN

/bin/sh
if [ ! -f /etc/shells ]; then
 echo "/bin/tcsh" >> /etc/shells
 echo "/bin/csh"	>> /etc/shells
else
 grep -q '^/bin/tcsh$' /etc/shells || \
 echo "/bin/tcsh" >> /etc/shells
 grep -q '^/bin/csh$'  /etc/shells || \
 echo "/bin/csh"	>> /etc/shells
fi

POSTUN

/bin/sh
if [ ! -x /bin/tcsh ]; then
 grep -v '^/bin/tcsh$'  /etc/shells | \
 grep -v '^/bin/csh$' > /etc/shells.rpm && \
 mv /etc/shells.rpm /etc/shells
fi