From 313a8f2ace741edbdb7556869474c5764adbfdd4 Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Mon, 15 Jun 2015 07:17:10 +0200 Subject: [PATCH] Revert "pkg: advertising the root shell menu isn't useful" This reverts commit 7030a38a702095902b23b6549c1cb707fd65b361. Avoids a warning on bootup when done. It may throw people off. --- pkg/+POST_INSTALL | 6 ++++++ pkg/+PRE_DEINSTALL | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/pkg/+POST_INSTALL b/pkg/+POST_INSTALL index cd4ba05a7..f78e8e3d7 100644 --- a/pkg/+POST_INSTALL +++ b/pkg/+POST_INSTALL @@ -1,3 +1,9 @@ +echo "Updating /etc/shells" +cp /etc/shells /etc/shells.bak +(grep -v /usr/local/etc/rc.initial /etc/shells.bak; \ + echo /usr/local/etc/rc.initial) > /etc/shells +rm -f /etc/shells.bak + echo "Registering root shell" pw usermod -n root -s /usr/local/etc/rc.initial diff --git a/pkg/+PRE_DEINSTALL b/pkg/+PRE_DEINSTALL index f5e9b57bf..ecc198429 100644 --- a/pkg/+PRE_DEINSTALL +++ b/pkg/+PRE_DEINSTALL @@ -1,6 +1,11 @@ echo "Resetting root shell" pw usermod -n root -s /bin/csh +echo "Updating /etc/shells" +cp /etc/shells /etc/shells.bak +(grep -v /usr/local/etc/rc.initial /etc/shells.bak) > /etc/shells +rm -f /etc/shells.bak + echo "Unhooking from /etc/rc" cp /etc/rc /etc/rc.bak tail -n +5 /etc/rc.bak > /etc/rc