Skip to content

Instantly share code, notes, and snippets.

@hedleysmith
Created July 14, 2013 21:13
Show Gist options
  • Select an option

  • Save hedleysmith/5996080 to your computer and use it in GitHub Desktop.

Select an option

Save hedleysmith/5996080 to your computer and use it in GitHub Desktop.
My zsh theme, based on ys
# Clean, simple and slick. All on one line.
# It is recommended to use with a dark background and the font Inconsolata.
# Colors: black, red, green, yellow, *blue, magenta, cyan, and white.
# Based on YS theme
# Machine name.
function box_name {
[ -f ~/.box-name ] && cat ~/.box-name || hostname -s
}
# Directory info.
local current_dir='${PWD/#$HOME/~}'
# Git info.
local git_info='$(git_prompt_info)'
ZSH_THEME_GIT_PROMPT_PREFIX=" %{$fg[white]%}on%{$reset_color%} git:%{$fg[cyan]%}"
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
ZSH_THEME_GIT_PROMPT_DIRTY=" %{$fg[red]%}x"
ZSH_THEME_GIT_PROMPT_CLEAN=" %{$fg[green]%}o"
# Prompt format: \n # USER at MACHINE in DIRECTORY on git:BRANCH STATE $
PROMPT="%{$terminfo[bold]$fg[blue]%}#%{$reset_color%} %{$fg[cyan]%}%n %{$fg[white]%}at %{$fg[green]%}$(box_name) %{$fg[white]%}in %{$terminfo[bold]$fg[yellow]%}${current_dir}%{$reset_color%} ${git_info} %{$terminfo[bold]$fg[red]%}$ %{$reset_color%}"
@hedleysmith

Copy link
Copy Markdown
Author

This theme looks great with the Solarized colour pallette http://ethanschoonover.com/solarized

@hedleysmith

Copy link
Copy Markdown
Author

And also looks great with the Inconsolata font: http://www.levien.com/type/myfonts/inconsolata.html (14pt)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment