-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.bashrc
More file actions
63 lines (54 loc) · 1.5 KB
/
.bashrc
File metadata and controls
63 lines (54 loc) · 1.5 KB
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
export LC_CTYPE=C
export LANG=C
export LSCOLOR="EHfxcxdxBxegecabagacad"
export PYTHONIOENCODING=utf-8
export OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES
cs_region=us-west-2
function addcred() {
read -p 'Table: ' table
read -sp 'Key: ' key
echo
if [ -z "$table" -o $(credstash -t $table -r $cs_region keys | grep ResourceNotFoundException) ]; then
echo "Table not found"
exit 1
fi
if [ $# -eq 2 ]; then
credstash -t $table -r $cs_region put $1 $2 -k $key
else
echo "Must pass a keyname and a value"
fi
}
function getcred() {
read -p 'Table: ' table
echo
if [ -z "$table" -o $(credstash -t $table -r $cs_region keys | grep ResourceNotFoundException) ]; then
echo "Table not found"
exit 1
fi
if [ $# -eq 1 ]; then
credstash -t $cs_sec_table -r $cs_region get $1
else
echo "Must pass a key name"
fi
}
function gitmm() {
stash=false
if [ ! $(git status | grep "nothing to commit, working tree clean") ]; then
git stash
stash=true
fi
curr_branch=$(git branch | grep \* | cut -d' ' -f2)
git checkout master
git pull
git checkout $curr_branch
git merge master --no-edit
if [ $stash ]; then
git stash apply
fi
}
alias ls='ls -GH'
alias ll='ls -al'
export PATH="/Library/Python/2.7/site-packages:$PATH"
export PATH="/Library/Frameworks/Python.framework/Versions/2.7/bin:$PATH"
eval "$(direnv hook bash)"
export PATH="/opt/local/bin:/opt/local/sbin:$PATH"