commit 9bb68e3c7707fad93f224b25006c7d13e83fac97 parent cafa51bd79ab1f7237726bce4e9d2420dd55e58b Author: Anders Damsgaard <anders@adamsgaard.dk> Date: Thu, 3 Oct 2019 13:45:12 +0200 Remove domain from PS1 Diffstat:
M | .profile | | | 4 | +++- |
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/.profile b/.profile @@ -6,5 +6,7 @@ export PATH HOME TERM ENV [ -f $HOME/.config/sh/profile ] && . $HOME/.config/sh/profile [ -f $HOME/.config/sh/commands ] && . $HOME/.config/sh/commands -export PS1="[32m${USER:=$(id -un)}@${HOSTNAME:=$(hostname)} [34m\$PWD[00m $( if (( USER_ID )); then print \$; else print \#; fi) " +HOSTNAME=${HOSTNAME:-$(uname -n)} +HOST=${HOSTNAME%%.*} +export PS1="[32m${USER:=$(id -un)}@${HOST} [34m\$PWD[00m $( if (( USER_ID )); then print \$; else print \#; fi) " export ENV=$HOME/.kshrc