From 1ab16323eafe4b9a0697b92561ca5463fe8f5b3a Mon Sep 17 00:00:00 2001 From: awy Date: Tue, 20 Aug 2024 19:06:17 +0300 Subject: dash as sh --- post_chroot.sh | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/post_chroot.sh b/post_chroot.sh index 005f114..7725289 100755 --- a/post_chroot.sh +++ b/post_chroot.sh @@ -79,4 +79,22 @@ if [ "$_kernelflag" -eq 1 ]; then grub-mkconfig -o /boot/grub/grub.cfg fi +# use dash as sh +pacman -Sy dash +ln -sfT dash /usr/bin/sh +mkdir -p /etc/pacman.d/hooks +cat <> /etc/pacman.d/hooks/bash.hook +[Trigger] +Type = Package +Operation = Install +Operation = Upgrade +Target = bash + +[Action] +Description = Re-pointing /bin/sh symlink to dash... +When = PostTransaction +Exec = /usr/bin/ln -sfT dash /usr/bin/sh +Depends = dash +EOL + rm /post_chroot.sh -- cgit v1.2.3