Compare commits

...

4 Commits

2 changed files with 13 additions and 1 deletions

View File

@@ -34,7 +34,7 @@ shopt -s checkwinsize
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
$()
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm*) color_prompt=yes;;
@@ -72,6 +72,15 @@ xterm*|rxvt*)
;;
esac
# Add goodies to PS1
export BASE_PS1="$PS1"
export BASE_PS1="$(echo "$BASE_PS1" | sed 's!\\\$ $!!g')"
export BASE_PS1_END=' \$ '
# show return value if prompt is nonzero
export BASH_GOODIES_RETURNVAL='$([ "$?" = 0 ] && echo "" || echo " \e[31m\][$?]\[\e[0m\]")'
PS1="${BASE_PS1}${BASH_GOODIES_RETURNVAL}${BASE_PS1_END}"
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"

View File

@@ -101,6 +101,9 @@ export PERL_MM_OPT="INSTALL_BASE=$HOME/perl5"
# aliases
alias less='less -i -r'
if which winget.exe >/dev/null 2>&1; then
alias winget="$(which winget.exe)"
fi
# profile variables that need to be defined late
[ -f "$HOME/.profile-post-local" ] && source "$HOME/.profile-post-local"