Created
January 18, 2015 23:27
-
-
Save mcy/8604b9b1178c45d6cabd 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
local return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})" | |
local user_host='%{$terminfo[bold]$fg[green]%}%n@%M%{$reset_color%}' | |
local current_dir='%{$terminfo[bold]$fg[blue]%} %~%{$reset_color%}' | |
local git_branch='$(git_prompt_info)%{$reset_color%}' | |
if [ $USER = 'root' ]; then | |
local prompt_char='%{$terminfo[bold]$fg[red]%}#' | |
else | |
local prompt_char='%B$' | |
fi | |
PROMPT="╭╼ ${user_host} ${current_dir} ${git_branch} | |
╰─-> ${prompt_char}%b " | |
RPS1="${return_code}" | |
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[yellow]%}‹" | |
ZSH_THEME_GIT_PROMPT_SUFFIX="› %{$reset_color%}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment