Created
January 10, 2020 00:47
-
-
Save Asoul/3dc2a52b7c82e33cabeb8d65837b1e6f to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# Git branch in prompt. | |
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' | |
} | |
# Execute function in prompt | |
setopt PROMPT_SUBST | |
# Enable color in prompt | |
autoload -U colors && colors | |
PROMPT='%{$fg[cyan]%}%n%{$reset_color%} @ %{$fg[red]%}%m:%{$reset_color%}%{$fg[yellow]%}%~%{$reset_color%}%{$fg[green]%}$(parse_git_branch)%{$reset_color%} $ ' | |
# Global Shortcut | |
alias subl='/Applications/Sublime\ Text.app/Contents/SharedSupport/bin/subl' | |
alias ls='ls -G' | |
alias python=/usr/local/bin/python3 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment