-
Notifications
You must be signed in to change notification settings - Fork 0
/
bashrc_mac
executable file
·50 lines (42 loc) · 1.22 KB
/
bashrc_mac
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
# 2009-09-30_at_19:22 make terminal got color
export CLICOLOR=1
export LSCOLORS=gxfxaxdxcxegedabagacad
# change prompt
export PS1="\w\$ "
extend_env () {
# $2 extend value
varname="$1"
extend_val="$2"
sep="$3"
eval "val=\$$varname"
echo $val | grep -q -s "$extend_val"
if [ $? -eq 1 ]; then
eval "${varname}=${extend_val}${sep}${val}"
eval "export $varname"
fi
}
export JAVA_HOME=`/usr/libexec/java_home`
extend_env "PATH" "$JAVA_HOME/bin" ":"
extend_env "PATH" "/usr/local/sbin" ":"
extend_env "PATH" "/usr/local/bin" ":"
extend_env "PATH" "/usr/local/share/npm/bin" ":"
PATH=/usr/local/bin:$PATH
if which pyenv > /dev/null; then
eval "$(pyenv init -)";
fi
SVN_EDITOR=/usr/bin/vi
export SVN_EDITOR
export PYTHON_HOME=/Library/Frameworks/Python.framework/Versions/Current
alias ls='ls -w'
alias ll='ls -alF'
alias la='ls -A'
alias l='ls -CF'
set -o vi
export ANT_OPTS="-Xmx1024m -XX:MaxPermSize=256m"
export HOMEBREW_GITHUB_API_TOKEN="c2675a02b566bac96cceefeb43b0df302eb9ec85"
export NVM_DIR="$HOME/.nvm"
. "$(brew --prefix nvm)/nvm.sh" --no-use
NODE_VERSION=`nvm version node`
export PATH="${PATH}:${NVM_DIR}/versions/node/${NODE_VERSION}/bin"
export REACT_EDITOR=nvim
source ~/.shortcut.sh