From 48fb56be13a43a6e5732f89633dac0783c1acfa8 Mon Sep 17 00:00:00 2001 From: Petr Sabata Date: May 23 2011 07:09:56 +0000 Subject: Try to add dash to /etc/shells every time, not just on new installs (#706138) --- diff --git a/dash.spec b/dash.spec index f2bcdb9..fd2eea5 100644 --- a/dash.spec +++ b/dash.spec @@ -1,6 +1,6 @@ Name: dash Version: 0.5.6 -Release: 4%{?dist} +Release: 5%{?dist} Summary: Small and fast POSIX-compliant shell Group: System Environment/Shells License: BSD @@ -26,13 +26,11 @@ mv %{buildroot}%{_bindir}/dash %{buildroot}/bin/ rm -rf %{buildroot}%{_bindir}/ %post -if [ $1 -eq 1 ]; then - grep -qF /bin/dash /etc/shells || echo '/bin/dash' >> /etc/shells -fi +grep -qF '^/bin/dash$' /etc/shells || echo '/bin/dash' >> /etc/shells %postun if [ $1 -eq 0 ]; then - sed -i '/\/bin\/dash/d' /etc/shells + sed -i '/^\/bin\/dash$/d' /etc/shells fi %files @@ -41,6 +39,10 @@ fi %{_datadir}/man/man1/dash.1.gz %changelog +* Mon May 23 2011 Petr Sabata - 0.5.6-5 +- Try to add dash to /etc/shells every time, not just on new installs (#706138) +- Also, make the grep regexps a bit more strict, just to be sure + * Thu May 19 2011 Petr Sabata - 0.5.6-4 - Install/remove dash from /etc/shells (#706138) - Buildroot and defattr cleanup