mirror of
				https://github.com/akelge/vim
				synced 2025-11-03 23:14:25 +00:00 
			
		
		
		
	Started personal prompt system
This commit is contained in:
		@ -27,5 +27,4 @@ setopt AUTO_CD
 | 
				
			|||||||
setopt AUTO_MENU
 | 
					setopt AUTO_MENU
 | 
				
			||||||
setopt no_MENU_COMPLETE
 | 
					setopt no_MENU_COMPLETE
 | 
				
			||||||
setopt AUTO_LIST
 | 
					setopt AUTO_LIST
 | 
				
			||||||
 | 
					 | 
				
			||||||
#  vim: set ts=4 sw=4 tw=0 ft=zsh : 
 | 
					#  vim: set ts=4 sw=4 tw=0 ft=zsh : 
 | 
				
			||||||
 | 
				
			|||||||
@ -1,6 +1,6 @@
 | 
				
			|||||||
#######################################################################################
 | 
					#######################################################################################
 | 
				
			||||||
# Start autocomplete
 | 
					# Start autocomplete
 | 
				
			||||||
autoload -U compinit; compinit
 | 
					autoload -U compinit; compinit -u
 | 
				
			||||||
autoload -U compsys;
 | 
					autoload -U compsys;
 | 
				
			||||||
compctl -g "*(-/)" + -g ".*(-/)" cd
 | 
					compctl -g "*(-/)" + -g ".*(-/)" cd
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -1,17 +1,29 @@
 | 
				
			|||||||
#######################################################################################
 | 
					#######################################################################################
 | 
				
			||||||
# Setup PROMPT
 | 
					 | 
				
			||||||
if [ ${TERM[0,5]} = "xterm" ] || [ ${TERM} = "rxvt" ]; then
 | 
					 | 
				
			||||||
  # We are on xterminal
 | 
					 | 
				
			||||||
  W="%{]2;::: %n at %m in %. :::%}"
 | 
					 | 
				
			||||||
  I="%{]1;%m::%.%}"
 | 
					 | 
				
			||||||
  L="%B%K{blue}%F{white}@%m::%2~ %f%k
 | 
					 | 
				
			||||||
%F{yellow}%#%f%b "
 | 
					 | 
				
			||||||
  PS1="$W$I$L"
 | 
					 | 
				
			||||||
  unset W I L
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
else
 | 
					# prompt_akel_setup() {
 | 
				
			||||||
  # We are not on xterminal
 | 
					    # precmd () {
 | 
				
			||||||
  PS1="%B[%l] %n@%m:%~ %#%b "
 | 
					 | 
				
			||||||
fi
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        # # Setup PROMPT
 | 
				
			||||||
 | 
					        # if [ ${TERM[0,5]} = "xterm" ] || [ ${TERM} = "rxvt" ]; then
 | 
				
			||||||
 | 
					            # # We are on xterminal
 | 
				
			||||||
 | 
					            # W="%{]2;::: %n at %m in %. :::%}"
 | 
				
			||||||
 | 
					            # I="%{]1;%m::%.%}"
 | 
				
			||||||
 | 
					            # L="%B%K{blue}%F{white}@%m::%2~ %f%k
 | 
				
			||||||
 | 
					# %F{yellow}%#%f%b "
 | 
				
			||||||
 | 
					            # PS1="$W$I$L"
 | 
				
			||||||
 | 
					            # unset W I L
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        # else
 | 
				
			||||||
 | 
					            # # We are not on xterminal
 | 
				
			||||||
 | 
					            # PS1="%B[%l] %n@%m:%~ %#%b "
 | 
				
			||||||
 | 
					        # fi
 | 
				
			||||||
 | 
					    # }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    # preexec () { }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# prompt_akel_setup
 | 
				
			||||||
 | 
					autoload -U promptinit;promptinit
 | 
				
			||||||
 | 
					prompt akel1
 | 
				
			||||||
#  vim: set ts=4 sw=4 tw=0 ft=zsh : 
 | 
					#  vim: set ts=4 sw=4 tw=0 ft=zsh : 
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										19
									
								
								zsh/zsh.d/zshfunctions/prompt_akel1_setup
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								zsh/zsh.d/zshfunctions/prompt_akel1_setup
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,19 @@
 | 
				
			|||||||
 | 
					function prompt_akel1_setup {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Setup PROMPT
 | 
				
			||||||
 | 
					if [ ${TERM[0,5]} = "xterm" ] || [ ${TERM} = "rxvt" ]; then
 | 
				
			||||||
 | 
					    # We are on xterminal
 | 
				
			||||||
 | 
					    W="%{]2;::: %n at %m in %. :::%}"
 | 
				
			||||||
 | 
					    I="%{]1;%m::%.%}"
 | 
				
			||||||
 | 
					    L="%B%K{blue}%F{white}@%m::%2~ %f%k
 | 
				
			||||||
 | 
					%F{yellow}%#%f%b "
 | 
				
			||||||
 | 
					    PS1="$W$I$L"
 | 
				
			||||||
 | 
					    unset W I L
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					else
 | 
				
			||||||
 | 
					    # We are not on xterminal
 | 
				
			||||||
 | 
					    PS1="%B[%l] %n@%m:%~ %#%b "
 | 
				
			||||||
 | 
					fi
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					prompt_akel1_setup
 | 
				
			||||||
@ -11,6 +11,10 @@ LIBRARY="/etc/zsh.d"
 | 
				
			|||||||
KERNLIB="${LIBRARY}/${KERNEL}"
 | 
					KERNLIB="${LIBRARY}/${KERNEL}"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function loadRC {
 | 
					function loadRC {
 | 
				
			||||||
 | 
					    if [ -d $1/zshfunctions ]; then
 | 
				
			||||||
 | 
					        fpath=($1/zshfunctions $fpath)
 | 
				
			||||||
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if [ -d $1 ]; then
 | 
					    if [ -d $1 ]; then
 | 
				
			||||||
        # for zshFile in $1/*[^~]; do
 | 
					        # for zshFile in $1/*[^~]; do
 | 
				
			||||||
        for zshFile in $1/*[^off\|~]; do
 | 
					        for zshFile in $1/*[^off\|~]; do
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user