Compare commits

..

7 Commits

4 changed files with 12 additions and 12 deletions

View File

@@ -31,8 +31,7 @@ export PATH="$PATH:$VCPKG_ROOT"
# if executing interactively
# execute .bashrc in the current login context
case $- in
*i*) ;;
*) return ;;
*i*) return ;;
esac
[ -z "${PS1-}" ] && return
[ -f "$HOME/.bashrc" ] && . "$HOME/.bashrc"

19
.bashrc
View File

@@ -6,8 +6,7 @@
#
case $- in
*i*) ;;
*) return ;;
*i*) return ;;
esac
[ -z "${PS1-}" ] && return
@@ -51,16 +50,16 @@ __regenprompt() {
local git=$(__lazy_git_ps1)
if [ $err -ne 0 ]; then
err="\[\033[$((COLUMNS - 4))G\033[01;31m\]${err}\[\033[0G\]"
err="\033[s\033[$((COLUMNS - 4))G${err}\033[u"
else unset err; fi
PS1="$err" # error code
PS1="$PS1\[\033[?25h\]" # show cursor
PS1="$PS1\[\033[01;35m\]\u@\h" # user@host
PS1="$PS1\[\033[00m\]:" # separator
PS1="$PS1\[\033[01;34m\]\w" # working directory
PS1="$PS1\[\033[01;93m\]${git}" # git branch
PS1="$PS1\[\033[00m\]\$ " # shell sign
PS1="\[\033[?25h\]" # show cursor
PS1="$PS1\[\033[01;35m\]\u@\h" # user@host
PS1="$PS1\[\033[00m\]:" # separator
PS1="$PS1\[\033[01;34m\]\w" # working directory
PS1="$PS1\[\033[01;93m\]$git" # git branch
PS1="$PS1\[\033[01;31m\]\[$err\]" # error code
PS1="$PS1\[\033[00m\]\$ " # shell sign
}
PROMPT_COMMAND=__regenprompt

1
etc/i3 Submodule

Submodule etc/i3 added at c59f51a0a9

1
etc/nvim Submodule

Submodule etc/nvim added at 6da6d4ffb9