-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbash_aliases
92 lines (76 loc) · 3.22 KB
/
bash_aliases
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# ALIASES
# temporary commands
alias reverseproxyssh='ssh -l ubuntu -i ~/Code/ReverseProxyServer.pem ec2-107-22-222-4.compute-1.amazonaws.com'
#general commands
alias rr='bundle exec rake routes | grep'
alias dotfiles='cd ~/dotfiles'
alias snip='cd ~/.vim/vim-addons/github-enricribas-snipmate-snippets/'
alias did='idonethis'
alias ali='vi ~/.bash_aliases'
alias reload='. ~/.bashrc'
alias inf='cd ~/Code/influitive-app'
alias gpr='hub pull-request -b influitive/influitive-app:development -h influitive/influitive-app:'
alias dqa='./script/deploy qa development'
#postgres
alias pg_start='pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start'
alias pg_stop='pg_ctl -D /usr/local/var/postgres stop'
alias postgres_push_leapfroggy='heroku pg:transfer --to HEROKU_POSTGRESQL_ORANGE_URL --from postgres://enric@localhost/leapfroggy_development'
#sublime
alias sublime_folder='cd /Users/dev/Library/Application\ Support/Sublime\ Text\ 2\Packages'
#mysql
alias mysql_start='mysql.server start'
alias mysql_stop='mysql.server stop'
#ruby
alias irbs="irb --simple-prompt"
#git commands
alias gca='git commit -a --amend --no-edit'
alias gc="git commit -m "
alias gco="git checkout "
alias dev="git checkout development"
alias gb="git branch -v"
alias gs="git status --short"
alias gd='git diff'
alias gdc='git diff --cached'
alias gah="git add --patch"
alias ga="git add "
alias gaa="git add . --all "
alias gu="git reset HEAD "
alias gff="git flow feature"
alias gpd="git push origin development"
alias glg='git log --color --decorate --oneline --graph'
alias pull='git pull --rebase && bundle && migrate'
alias git_reset_my_branch='git reset --hard HEAD'
alias git_make_alias='git config alias.'
alias gmt='git mergetool -y'
alias gm='git merge'
alias pr='hub pull-request -b development -h influitive/influitive-app:'
# rails development
alias taild='tail -f log/development.log'
alias tailt='tail -f log/test.log'
alias rk='bundle exec rake'
alias rs='bundle exec rspec -f d'
alias rsa='bundle exec rspec spec --tag ~slow --tag ~type:feature'
alias rsai='bundle exec rspec spec'
alias pc='heroku run console -ainfluitive-prod'
alias nc='heroku run console -ainfluitive-narciservice-prod'
alias zrs='zeus rspec -f d '
# project related
alias staging_migrate_status="heroku run bundle exec rake db:migrate:status -a influitive-staging |grep down |cut -d' ' -f7"
alias restore_qa='heroku pgbackups:restore -a influitive-qa-interview -confirm influitive-qa-interview'
alias stage="git push staging development:master"
alias pre_stage='git push staging pre-prod:master'
alias stage_seed='heroku run rake apartment:seed --app influitive-staging'
alias stage_migrate='heroku run rake apartment:migrate --app influitive-staging'
function gcof() { git checkout feature/APP-"$@" ; }
function gpf() { git push origin feature/APP-"$@" ; }
# postgres commands
alias pg_start="pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start"
alias pg_stop="pg_ctl -D /usr/local/var/postgres stop -s -m fast"
# rails
alias migrate='bundle exec rake apartment:migrate db:test:prepare'
alias redo='bundle exec rake apartment:migrate:redo'
alias r="bundle exec rails"
alias be="bundle exec "
# emasc
alias e='emacsclient -t'
alias ec='emacsclient --no-wait -c'