diff options
author | Michael Louwrens <mlouwrens@entersekt.com> | 2018-02-10 21:50:59 +0300 |
---|---|---|
committer | Michael Louwrens <mlouwrens@entersekt.com> | 2018-02-10 21:50:59 +0300 |
commit | 06802647a1919c8f51bbead78104a6093e137e5a (patch) | |
tree | 64ba205debdb6bda8b06eb7160eb4009394e0d0f /powerlevel9k.zsh-theme | |
parent | 7b8656f8e79fb369b91b93cb3cbbe437935bb893 (diff) |
change sudo detection method
Diffstat (limited to 'powerlevel9k.zsh-theme')
-rwxr-xr-x | powerlevel9k.zsh-theme | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/powerlevel9k.zsh-theme b/powerlevel9k.zsh-theme index 40b38a22..17af7ccb 100755 --- a/powerlevel9k.zsh-theme +++ b/powerlevel9k.zsh-theme @@ -609,7 +609,7 @@ prompt_context() { current_state="ROOT" elif [[ -n "$SSH_CLIENT" || -n "$SSH_TTY" ]]; then current_state="REMOTE" - elif sudo -n uptime >/dev/null 2>&1; then + elif sudo -n true 2>/dev/null; then current_statue="SUDO" fi @@ -632,7 +632,7 @@ prompt_user() { "FOREGROUND_COLOR" "yellow" "VISUAL_IDENTIFIER" "ROOT_ICON" ) - elif sudo -n uptime >/dev/null 2>&1; then + elif sudo -n true 2>/dev/null; then user_state=( "STATE" "SUDO" "CONTENT" "${POWERLEVEL9K_USER_TEMPLATE}" |