-
Notifications
You must be signed in to change notification settings - Fork 0
/
bash_profile
57 lines (37 loc) · 1017 Bytes
/
bash_profile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#########
# general
#########
# for OSX to stop nagging about zshell
export BASH_SILENCE_DEPRECATION_WARNING=1
export PATH="$HOME/.local/bin:$PATH"
# ssh
ssh-agent && ssh-add
## bash & completion
if [ -f $LOCAL/etc/bash_completion ]; then
source $LOCAL/etc/bash_completion
fi
if [ -f "/opt/homebrew/bin/brew" ]; then
eval "$(/opt/homebrew/bin/brew shellenv)"
fi
## nvim & editor
NVIM_PATH=`which nvim`
if [ -x "$NVIM_PATH" ]; then
alias vim=nvim
else
echo "nvim not installed"
fi
export EDITOR=vim
export VISUAL=$EDITOR
set -o vi
####
# git
####
if [[ `which brew` && -f "$(brew --prefix bash-git-prompt)/share/gitprompt.sh" ]]; then
GIT_PROMPT_THEME=Default
source "$(brew --prefix bash-git-prompt)/share/gitprompt.sh"
else
# Probably somewhat out of date...
source $HOME/profile/git-completion.bash
fi
export GIT_PS1_SHOWDIRTYSTATE=1
export PS1='\[\033[00;33m\]\t\n\[\033[00;37m\]\u@\h\[\033[00m\]:\[\033[00;36m\]\W\[\033[00m\]\[\033[00;33m\]$(__git_ps1 " (%s)")\[\033[00m\]\$ '