-
Notifications
You must be signed in to change notification settings - Fork 0
/
.aliases
44 lines (40 loc) · 1.51 KB
/
.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
alias ne='emacs -nw'
alias v='vim'
# Rails aliases
alias r='rails s'
alias gs='git status'
alias gc='git commit -m $1'
alias ga='git add -p $1'
alias bi='bundle install --without production'
alias test='bundle exec rspec spec --tag focus'
alias g='bundle exec rake db:test:prepare && bundle exec guard'
alias ci='git add -A . && git commit -a -m $1'
alias pop='bundle exec rake db:populate'
alias dbclean='bundle exec rake db:reset && bundle exec rake db:migrate && pop'
alias dbreset='dbclean && bundle exec rake db:populate || bundle exec db:seed'
alias dbi='bundle exec rake db:migrate && bundle exec rake db:populate || bundle exec db:seed'
# some more ls aliases
alias ls='ls -hF --color' # add colors for filetype recognition
alias lx='ls -lXB' # sort by extension
alias lk='ls -lSr' # sort by size
alias la='ls -Al' # show hidden files
alias lr='ls -lR' # recursice ls
alias lt='ls -ltr' # sort by date
alias lm='ls -al |more' # pipe through 'more'
alias tree='tree -Cs' # nice alternative to 'ls'
alias ll='ls -l' # long listing
alias l='ls -hF --color' # quick listing
alias lsize='ls --sort=size -lhr' # list by size
alias lsd='ls -l | grep "^d"' #list only directories
# Command substiution
alias ff='sudo find / -name $1'
alias df='df -h -x tmpfs -x usbfs'
alias psg='ps -ef | grep $1'
alias h='history | grep $1'
alias rm='rm -i'
alias i='sudo apt-get install $1'
alias as='aptitude search '
alias sb='source ~/.bashrc && source ~/.profile'
alias ..='cd ..'
alias ph='history | cut -c 8-'
alias phs='history | cut -c 8- | grep'