Created
January 28, 2022 08:45
-
-
Save dmigo/9aafd00a5fa7c22e2f6d6e7e6430bca8 to your computer and use it in GitHub Desktop.
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
# Let pyenv decide which version of python to use | |
# Taken from StackOverflow https://stackoverflow.com/a/70307478/788833 | |
export PYENV_ROOT="$HOME/.pyenv" | |
export PATH="$PYENV_ROOT/bin:$PATH" | |
eval "$(pyenv init --path)" | |
eval "$(pyenv init -)" | |
eval "$(pyenv virtualenv-init -)" | |
# Activate Rust | |
source $HOME/.cargo/env | |
# Prompt | |
export STARSHIP_CONFIG=~/.config/starship.toml | |
eval "$(starship init zsh)" | |
# Syntax Highlighting | |
source $HOMEBREW_PREFIX/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh | |
# Autocompletion | |
if type brew &>/dev/null; then | |
FPATH=$(brew --prefix)/share/zsh-completions:$FPATH | |
# Make case insensitive | |
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}' | |
autoload -Uz compinit | |
compinit | |
fi | |
# Autosuggestion | |
source $HOMEBREW_PREFIX/share/zsh-autosuggestions/zsh-autosuggestions.zsh | |
# History Substring Search | |
source $HOMEBREW_PREFIX/share/zsh-history-substring-search/zsh-history-substring-search.zsh | |
bindkey '^[[A' history-substring-search-up | |
bindkey '^[[B' history-substring-search-down | |
# Aliases | |
alias ls='ls -G' | |
alias grep='grep --color=auto' | |
alias ..='cd ..' | |
alias ...='cd ../..' | |
alias ....='cd ../../..' | |
alias g='git' | |
alias cal='gcal --starting-day=1' | |
alias weather='curl v2.wttr.in' | |
alias stat=htop | |
alias k=kubectl | |
alias l='exa -l --icons' | |
alias tree='exa --tree --long --icons' | |
alias hyperconfig='code /Users/dmigo/.hyper.js' | |
# Utility Functions | |
func zshconfig(){ | |
vim ~/.zshrc | |
source ~/.zshrc | |
} | |
func vimconfig(){ | |
vim ~/.vimrc | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment