This commit is contained in:
2025-03-06 19:34:04 -08:00
parent 5cfd1ddbb5
commit 311db4a0a5
5 changed files with 45 additions and 34 deletions

21
.bashrc
View File

@@ -56,19 +56,11 @@ if [ -n "$force_color_prompt" ]; then
fi
fi
#if [ "$color_prompt" = yes ]; then
# PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
#else
# PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
#fi
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
source ~/.local/scripts/git-prompt.sh
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[01;31m\]$(parse_git_branch)\[\033[00m\]\$ '
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]$(__git_ps1 " (%s)") \$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w $(parse_git_branch)\$ '
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
@@ -126,7 +118,12 @@ if ! shopt -oq posix; then
fi
fi
PATH=$PATH:~/.local/bin/
alias vim='nvim'
alias ssh='ssh -XC'
alias xfreerdp='xfreerdp +clipboard /dynamic-resolution'
alias xfreerdp='xfreerdp +clipboard /dynamic-resolution '
# Set up fzf key bindings and fuzzy completion
eval "$(fzf --bash)"