Last active
October 31, 2017 11:14
-
-
Save imliam/24f885719fa2b8c0e8dace6257154774 to your computer and use it in GitHub Desktop.
Commonly used bash aliases
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Misc. Commands ## | |
alias h='cd ~' | |
alias c='clear' | |
alias ls='ls -alh' | |
alias pubkey="/bin/cat ~/.ssh/id_rsa.pub | pbcopy" | |
## A quick way to get out of the current directory ## | |
alias ..='cd ../' | |
alias ...='cd ../../' | |
alias ....='cd ../../../' | |
alias .....='cd ../../../../' | |
## Quickly edit hosts ## | |
alias hosts='sudo vim /etc/hosts' | |
## PHP and Laravel Command Line Tools ## | |
alias pa='php artisan' | |
alias art='php artisan' | |
alias artisan='php artisan' | |
alias test='clear && phpunit' | |
alias phpunit='vendor/bin/phpunit' | |
alias phpspec='vendor/bin/phpspec' | |
alias tinker="php artisan tinker --env=local" | |
alias autoload='composer dump-autoload' | |
alias db-reset="php artisan migrate:reset && php artisan migrate --seed" | |
## Colorize the grep command output for ease of use (good for log files) ## | |
alias grep='grep --color=auto' | |
alias egrep='egrep --color=auto' | |
alias fgrep='fgrep --color=auto' | |
## Colorize the ls output ## | |
alias ls='ls --color=auto' ## Use a long listing format ## | |
alias ll='ls -lah' ## Show hidden files ## | |
alias l.='ls -d .* --color=auto' | |
## Deal with the last edited files | |
alias lst='ls -lastr' | |
alias last='vim `ls -tr | tail -l`' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment