ssh kitten: Add MacPorts paths to the common locations for login shell

This commit is contained in:
pagedown 2022-06-28 11:43:19 +08:00
parent 1652d41992
commit 185d959f25
No known key found for this signature in database
GPG Key ID: E921CF18AC8FF6EB

View File

@ -202,11 +202,11 @@ prepare_for_exec() {
/*) ;;
*)
if ! command -v "$login_shell" > /dev/null 2> /dev/null; then
for i in /opt/homebrew/bin /opt/homebrew/sbin /usr/local/bin /usr/bin /bin /usr/sbin /sbin
for i in /opt/homebrew/bin /opt/homebrew/sbin /opt/local/bin /opt/local/sbin /usr/local/bin /usr/bin /bin /usr/sbin /sbin
do
if [ -x "$i/$login_shell" ]; then
login_shell="$i/$login_shell"
break;
break
fi
done
fi