purs: show user when root

This commit is contained in:
Timothy DeHerrera 2020-07-20 18:45:25 -06:00
parent 364a25a7f2
commit cd44832dc1
No known key found for this signature in database
GPG key ID: 8985725DB5B0C122

View file

@ -1,5 +1,9 @@
function zle-line-init zle-keymap-select { function zle-line-init zle-keymap-select {
PROMPT=`@PURS@/bin/purs prompt -us -k "$KEYMAP" -r "$?" --venv "${${VIRTUAL_ENV:t}%-*}"` if [[ $USER == root ]]; then
PROMPT=`@PURS@/bin/purs prompt -u -k "$KEYMAP" -r "$?" --venv "${${VIRTUAL_ENV:t}%-*}"`
else
PROMPT=`@PURS@/bin/purs prompt -us -k "$KEYMAP" -r "$?" --venv "${${VIRTUAL_ENV:t}%-*}"`
fi
zle reset-prompt zle reset-prompt
} }
zle -N zle-line-init zle -N zle-line-init