-
Notifications
You must be signed in to change notification settings - Fork 0
/
.bashrc
66 lines (52 loc) · 1.58 KB
/
.bashrc
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
56
57
58
59
60
61
62
63
64
65
66
# basics
export EDITOR=nvim
export PROMPT_COMMAND='history -a'
export HISTSIZE=100000
shopt -s histappend
# prompt
git_branch () {
git branch 2>/dev/null | grep -e '\* ' | sed 's/^..\(.*\)/\1/'
}
branch_prompt () {
BRANCH=$(git_branch)
if [ -n "$BRANCH" ]; then echo -n " $BRANCH"; fi
}
PS1="\[\e[0m\][\[\e[36;40m\]\u\[\e[0m\]@\[\e[36;40m\]\h\[\e[0m\] \[\e[32;40m\]\w\[\e[0m\]\[\e[33;40m\]\$(branch_prompt)\[\e[0m\]]$ \[\e[0m\]"
# aliases
alias ls="ls -G"
alias ll="ls -al"
alias grep="grep --color"
alias stripcolors="sed -e 's/\\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]//g'"
alias vim="nvim"
alias vimdiff="nvim -d"
alias be="bundle exec"
alias ios="open /Applications/Xcode.app/Contents/Developer/Applications/Simulator.app"
eval "$(hub alias -s)"
export PATH="$HOME/bin:$PATH"
export PATH="$HOME/git/tools/shell-scripts:$PATH"
# typos
alias bim="vim"
alias got="git"
alias giit="git"
# lang
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
# node.js
# export NVM_DIR="$HOME/.nvm"
# . "/usr/local/opt/nvm/nvm.sh"
# export PATH="$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:$PATH"
# ruby
# eval "$(rbenv init -)"
# python
# export PATH="/usr/local/opt/[email protected]/bin:$PATH"
# if command -v pyenv 1>/dev/null 2>&1; then
# eval "$(pyenv init -)"
# fi
# tmux
alias tmux="tmux -2"
alias irssi="TERM='screen-256color' irssi"
[ -f ~/.fzf.bash ] && source ~/.fzf.bash
[ -f /usr/local/etc/bash_completion ] && . /usr/local/etc/bash_completion
# Fix font smoothing in wine
export FREETYPE_PROPERTIES="truetype:interpreter-version=35"
launchctl setenv FREETYPE_PROPERTIES $FREETYPE_PROPERTIES