From bce34c8e40dad5a020488aca8dae74699c140eb5 Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Fri, 16 Dec 2016 12:49:59 +1100 Subject: [PATCH] Shell: Fix ksh on BSD, closes #539 --- neofetch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/neofetch b/neofetch index f4551dab..23c6f1dc 100755 --- a/neofetch +++ b/neofetch @@ -500,9 +500,10 @@ get_shell() { case "${SHELL##*/}" in "bash") shell+="${BASH_VERSION/-*}" ;; - "mksh") + "mksh" | "ksh") shell+="$("$SHELL" -c 'printf "%s" "$KSH_VERSION"')" shell="${shell/ * KSH}" + shell="${shell/version}" ;; *) @@ -513,7 +514,6 @@ get_shell() { # Remove unwanted info shell="${shell/, version}" - shell="${shell/version * sh/ksh}" shell="${shell/xonsh\//xonsh }" shell="${shell/options*}" shell="${shell/\(*\)}"