diff --git a/desk b/desk index 5e5aea8..7b786f4 100755 --- a/desk +++ b/desk @@ -287,7 +287,7 @@ get_running_shell() { else # Strip leading dash for login shells. # If the parent process is a login shell, guess bash. - local CMDLINE_SHELL=$(ps -o args -p $PPID | tail -1 | sed -e 's/login/bash/' -e 's/^-//') + local CMDLINE_SHELL=$(ps -o comm= -p $PPID | tail -1 | sed -e 's/login/bash/' -e 's/^-//') fi if [ ! -z "$CMDLINE_SHELL" ]; then