forked from square/maximum-awesome
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathzshrc
59 lines (43 loc) · 1.95 KB
/
zshrc
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
ZSH=$HOME/.oh-my-zsh
# You can change the theme with another one:
# https://github.com/robbyrussell/oh-my-zsh/wiki/themes
ZSH_THEME="robbyrussell"
# Useful plugins for Rails development with Sublime Text
plugins=(gitfast last-working-dir common-aliases sublime zsh-syntax-highlighting history-substring-search)
plugins+=(zsh-nvm)
plugins+=(git wd tmux)
# Prevent Homebrew from reporting - https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Analytics.md
export HOMEBREW_NO_ANALYTICS=1
# Actually load Oh-My-Zsh
source "${ZSH}/oh-my-zsh.sh"
unalias rm # No interactive rm by default (brought by plugins/common-aliases)
# Load rbenv if installed
export PATH="${HOME}/.rbenv/bin:${PATH}"
type -a rbenv > /dev/null && eval "$(rbenv init -)"
# Rails and Ruby uses the local `bin` folder to store binstubs.
# So instead of running `bin/rails` like the doc says, just run `rails`
# Same for `./node_modules/.bin` and nodejs
export PATH="./bin:./node_modules/.bin:${PATH}:/usr/local/sbin"
# Store your own aliases in the ~/.aliases file and load the here.
[[ -f "$HOME/.aliases" ]] && source "$HOME/.aliases"
# Encoding stuff for the terminal
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
export BUNDLER_EDITOR="'/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl' -a"
# VIM
bindkey -v
digitalocean() { mosh [email protected] }
ngrokstart() { ngrok http 3000 }
tmuxk() { tmux kill-session }
gupdate() { gco master && git pull origin master && git fetch && git sweep && bundle install && yarn install && rails db:migrate }
code() { cd ~/code }
mycode() { cd ~/code/ajdubovoy }
phoenix() { cd ~/code/vinitiet/RP_phoenix }
frog() { cd ~/code/vinitiet/RP_frog }
wpds() { webpack-dev-server }
herokudeploy() { git push heroku master }
herokustage() { git push staging master }
fulldeploy() { gupdate && herokudeploy }
fullstage() { gupdate && herokustage }
sp() { RAILS_ENV=production bundle exec rails s }
sd() { RAILS_ENV=development bundle exec rails s }