Created
September 4, 2019 22:34
-
-
Save anthonybaldwin/381259a86ceb884476baf0416a1ce4a5 to your computer and use it in GitHub Desktop.
.zshrc
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
## Weather ## | |
# w 93101 | |
# w "blue springs" | |
# weather "kansas city" | |
alias weather='w() { | |
if [ $1 ]; then | |
curl wttr.in/$1 | |
else | |
curl wttr.in | |
fi | |
};w' | |
alias w=weather | |
## Crypto ## | |
# $1 = btc, eth, ltc, etc. | |
# $2 = 30m, 1h, 1d, 5d, 30d, etc. | |
alias crypto='c() { | |
if [ $2 ]; then | |
curl rate.sx/$1@$2 | |
elif [ $1 ]; then | |
curl rate.sx/$1 | |
else | |
curl rate.sx | |
fi | |
};c' | |
alias c=crypto | |
## Set title ## | |
alias title='t(){ | |
echo -e "\033];$1\007" | |
};t' | |
alias t=title | |
## IDE ## | |
alias pstorm="open -a PhpStorm $1" | |
alias idea="open -a IntelliJ\ IDEA\ CE $1" | |
## Custom comamnds ## | |
bindkey "[D" backward-word | |
bindkey "[C" forward-word | |
bindkey "^[a" beginning-of-line | |
bindkey "^[e" end-of-line | |
## quick way to get out of current directory | |
alias ..='cd ..' | |
alias ...='cd ../../../' | |
alias ....='cd ../../../../' | |
alias .....='cd ../../../../' | |
alias .4='cd ../../../../' | |
alias .5='cd ../../../../..' | |
## install colordiff package 🙂 | |
alias diff=colordiff | |
## kubectl | |
alias ktl=kubectl | |
## thefuck | |
eval $(thefuck --alias) | |
source /usr/local/share/zsh-autosuggestions/zsh-autosuggestions.zsh | |
source /usr/local/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh | |
# The next line updates PATH for the Google Cloud SDK. | |
if [ -f '/Users/anthonybaldwin/google-cloud-sdk/path.zsh.inc' ]; then . '/Users/anthonybaldwin/google-cloud-sdk/path.zsh.inc'; fi | |
# The next line enables shell command completion for gcloud. | |
if [ -f '/Users/anthonybaldwin/google-cloud-sdk/completion.zsh.inc' ]; then . '/Users/anthonybaldwin/google-cloud-sdk/completion.zsh.inc'; fi | |
export PATH="/usr/local/opt/openssl/bin:$PATH" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment