mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-12-16 00:47:13 +00:00
Shell: Fix ksh on BSD, closes #539
This commit is contained in:
4
neofetch
4
neofetch
@@ -500,9 +500,10 @@ get_shell() {
|
|||||||
case "${SHELL##*/}" in
|
case "${SHELL##*/}" in
|
||||||
"bash") shell+="${BASH_VERSION/-*}" ;;
|
"bash") shell+="${BASH_VERSION/-*}" ;;
|
||||||
|
|
||||||
"mksh")
|
"mksh" | "ksh")
|
||||||
shell+="$("$SHELL" -c 'printf "%s" "$KSH_VERSION"')"
|
shell+="$("$SHELL" -c 'printf "%s" "$KSH_VERSION"')"
|
||||||
shell="${shell/ * KSH}"
|
shell="${shell/ * KSH}"
|
||||||
|
shell="${shell/version}"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
*)
|
*)
|
||||||
@@ -513,7 +514,6 @@ get_shell() {
|
|||||||
|
|
||||||
# Remove unwanted info
|
# Remove unwanted info
|
||||||
shell="${shell/, version}"
|
shell="${shell/, version}"
|
||||||
shell="${shell/version * sh/ksh}"
|
|
||||||
shell="${shell/xonsh\//xonsh }"
|
shell="${shell/xonsh\//xonsh }"
|
||||||
shell="${shell/options*}"
|
shell="${shell/options*}"
|
||||||
shell="${shell/\(*\)}"
|
shell="${shell/\(*\)}"
|
||||||
|
|||||||
Reference in New Issue
Block a user