aboutsummaryrefslogtreecommitdiff
path: root/check
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-11-30 15:03:30 +1300
committerTom Ryder <tom@sanctum.geek.nz>2018-11-30 15:03:30 +1300
commit66c2c1e9218b53ee0000423561e7a8a4b7d5902b (patch)
treee21ee6a517f3f4d6fdf1ea8095ea1eb9d215d033 /check
parentRemove redundant element from install scripts path (diff)
downloaddotfiles-66c2c1e9218b53ee0000423561e7a8a4b7d5902b.tar.gz
dotfiles-66c2c1e9218b53ee0000423561e7a8a4b7d5902b.zip
Check value of login shell more thoroughly
Some old GNU make(1) implementations (and possibly others) force SHELL to /bin/sh, so let's check the value more directly.
Diffstat (limited to 'check')
-rw-r--r--check/login-shell.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/check/login-shell.sh b/check/login-shell.sh
index 2972d98d..88eac59e 100644
--- a/check/login-shell.sh
+++ b/check/login-shell.sh
@@ -1,10 +1,12 @@
-target=check-sh
-case ${SHELL##*/} in
+shell=$(getent passwd "$USER" | cut -d: -f7)
+case ${shell##*/} in
bash)
target=check-bash ;;
ksh|ksh88|ksh93|mksh|pdksh)
target=check-ksh ;;
zsh)
target=check-zsh ;;
+ *)
+ target=check-sh ;;
esac
make "$target"