Skip to content

Latest commit

 

History

History
117 lines (73 loc) · 2.81 KB

README.md

File metadata and controls

117 lines (73 loc) · 2.81 KB

git-prompt.zsh examples

You can test the configurations shown below by sourcing the .zsh files from the examples directory. Once you have found a configuration that you like, source it in your .zshrc.

Preview all examples directly in Zsh

git clone https://github.com/woefe/git-prompt.zsh
cd git-prompt.zsh

examples/print_examples.sh

Examples

Ascii

A prompt using only ASCII characters.

Load this example: source examples/ascii.zsh

../hello_world master^1 o1+1..2>

This example mimics the bash-git-prompt informative git prompt for bash.

Load this example: source examples/bashgitprompt.zsh

~/workspace/hello_world [master ⟳ ↑1|●1✚1…2⚑1]
20:46 $

Compact

Compact prompt without counts.

Load this example: source examples/compact.zsh

..space/hello_world master↑|●✚…❯

Default

Same as shown in screenshot.svg.

Load this example: source examples/default.zsh

..lo_world [master↑1|●1✚1…2] ❯❯❯

Multi-line prompt

Load this example: source examples/multiline.zsh

┏╸~/workspace/hello_world · ⎇ master ⤳ origin/master↑1 ‹●1✚1…2›
┗╸❯❯❯

Pure clone

This clone of the Pure prompt has support for Python virtualenvs, but none of the timing features or a vi mode. If you are using fzf, source the example after sourcing fzf's keybindings.

If you want to try other examples again after sourcing the Pure example, you might have to restart your shell, because this prompt will always print a newline between prompts.

Load this example: source examples/pure.zsh

~/workspace/hello_world master↑1 ●1✚1…2
❯

Git status on the right

Load this example: source examples/rprompt.zsh

~/workspace/hello_world ≻≻≻         ≺ master⟳ ↑1 ●1✚1…2

Woefe's prompt (wprompt)

The wprompt example is similar to the multi-line and Pure examples, but with optional vi-mode and the secondary prompt enabled.

If you want to try other examples again after sourcing this example, you might have to restart your shell, because this prompt will always print a newline between prompts.

Load this example: source examples/wprompt.zsh

┏╸~/workspace/hello_world · ⎇ master↑1 · ●1✚1…2
┗╸❯❯❯