Prechádzať zdrojové kódy

Updated the prompt to be easier to read and edit as well as adding a FQDN rather than just hostname.

thisnthat 3 rokov pred
rodič
commit
19d1508dc4
1 zmenil súbory, kde vykonal 12 pridanie a 3 odobranie
  1. 12 3
      thisnthat.zsh-theme

+ 12 - 3
thisnthat.zsh-theme

@@ -10,11 +10,20 @@ else
 fi
 
 # Set the prompt
-#PROMPT="%{$fg[$USER_COLOR]%}%n@%m%{$reset_color%} %{$fg_bold[blue]%}%~%{$reset_color%} $(git_prompt_info)"$'\n'"%{$fg[$USER_COLOR]%}>%{$reset_color%} "
-PROMPT='%{$fg[$USER_COLOR]%}%n@%m%{$reset_color%} %{$fg_bold[blue]%}%~%{$reset_color%}$(git_prompt_info)'$'\n''%{$fg[$USER_COLOR]%}>%{$reset_color%} '
+#PROMPT="%{$fg[$USER_COLOR]%}%n@%M%{$reset_color%} %{$fg_bold[blue]%}%~%{$reset_color%} $(git_prompt_info)"$'\n'"%{$fg[$USER_COLOR]%}>%{$reset_color%} "
+#PROMPT='%{$fg[$USER_COLOR]%}%n@%M%{$reset_color%} %{$fg_bold[blue]%}%~%{$reset_color%}$(git_prompt_info)'$'\n''%{$fg[$USER_COLOR]%}>%{$reset_color%} '
+
+FQDN=`hostname -f`
+echo $FQDN
+HOST_NAME="%{$fg[$USER_COLOR]%}%n@${FQDN}%{$reset_color%}"
+LOCATION="%{$fg_bold[blue]%}%~%{$reset_color%}"
+LINE_PROMPT="%{$fg[$USER_COLOR]%}>%{$reset_color%} "
+NEWLINE=$'\n'
+PROMPT="${HOST_NAME} ${LOCATION} $(git_prompt_info) ${NEWLINE}${LINE_PROMPT}"
 
 # git prompt data
-ZSH_THEME_GIT_PROMPT_PREFIX=" on %{$fg[magenta]%}"
+ZSH_THEME_GIT_PROMPT_PREFIX="on %{$fg[magenta]%}"
 ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
 ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[red]%} ✗"
 ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[green] ✔"
+~