dallas.zsh-theme 1.4 KB

123456789101112131415161718192021222324252627
  1. # Personalized!
  2. # Grab the current date (%D) and time (%T) wrapped in {}: {%D %T}
  3. DALLAS_CURRENT_TIME_="%{$fg[white]%}{%{$fg[yellow]%}%D %T%{$fg[white]%}}%{$reset_color%}"
  4. # Grab the current machine name: muscato
  5. DALLAS_CURRENT_MACH_="%{$fg[green]%}%m%{$fg[white]%}:%{$reset_color%}"
  6. # Grab the current filepath, use shortcuts: ~/Desktop
  7. # Append the current git branch, if in a git repository: ~aw@master
  8. DALLAS_CURRENT_LOCA_="%{$fg[cyan]%}%~\$(git_prompt_info)%{$reset_color%}\$(parse_git_dirty)"
  9. # Grab the current username: dallas
  10. DALLAS_CURRENT_USER_="%{$fg[red]%}%n%{$reset_color%}"
  11. # Use a % for normal users and a # for privileged (root) users.
  12. DALLAS_PROMPT_CHAR_="%{$fg[white]%}%(!.#.%%)%{$reset_color%}"
  13. # For the git prompt, use a white @ and blue text for the branch name
  14. ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[white]%}@%{$fg[blue]%}"
  15. # Close it all off by resetting the color and styles.
  16. ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
  17. # Do nothing if the branch is clean (no changes).
  18. ZSH_THEME_GIT_PROMPT_CLEAN=""
  19. # Add 3 cyan ✗s if this branch is diiirrrty! Dirty branch!
  20. ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[cyan]%}✗✗✗"
  21. ZSH_THEME_RUBY_PROMPT_PREFIX="%{$fg[white]%}[%{$fg[magenta]%}"
  22. ZSH_THEME_RUBY_PROMPT_SUFFIX="%{$fg[white]%}]%{$reset_color%}"
  23. # Put it all together!
  24. PROMPT="$DALLAS_CURRENT_TIME_\$(ruby_prompt_info)$DALLAS_CURRENT_MACH_$DALLAS_CURRENT_LOCA_ $DALLAS_CURRENT_USER_$DALLAS_PROMPT_CHAR_ "