Merged detached head into master

This commit is contained in:
Jakobus Schürz 2020-07-14 00:54:59 +02:00
parent 0a8cffb3b9
commit 2656558774

8
PS1
View file

@ -1,11 +1,11 @@
# /etc/profile.d/PS1.sh: executed by Bourne-compatible login shells.
parse_git_branch() {
local LBRANCH="$(git branch 2>/dev/null | sed -ne 's/* \(.*\)/ \1/p'|tr -d \"[:blank:]\")"
local RBRANCH="$( git rev-parse --symbolic-full-name --abbrev-ref @{u} 2>/dev/null |tr -d \"[:blank:]\" )"
local LBRANCH="$(git branch 2>/dev/null | sed -ne 's/* \(.*\)/ \1/p'|sed -e 's/^[[:blank:]]*//;s/[[:blank:]]*$//')"
local RBRANCH="$( git rev-parse --symbolic-full-name --abbrev-ref @{u} 2>/dev/null |sed -e 's/^[[:blank:]]*//' )"
[ -z "${RBRANCH-x}" ] && unset RBRANCH
local BRANCH="$LBRANCH ${RBRANCH+->} $RBRANCH"
[ -z "${LBRANCH+x}" -o -z "${RBRANCH}" ] || echo "($BRANCH)"
local BRANCH="${LBRANCH}${RBRANCH+ -> }${RBRANCH}"
[ -z "${LBRANCH+x}" ] || echo "($BRANCH)"
}
set_label() {