mirror of
				https://github.com/ohmyzsh/ohmyzsh.git
				synced 2025-11-04 13:21:19 +08:00 
			
		
		
		
	add in xterms / title hacks
This commit is contained in:
		
							parent
							
								
									bd5826980e
								
							
						
					
					
						commit
						2b61a2aa3a
					
				
							
								
								
									
										16
									
								
								xterms.zsh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								xterms.zsh
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,16 @@
 | 
			
		||||
# Specific to xterms, such as OS X terminal
 | 
			
		||||
 | 
			
		||||
if [[ "${TERM}" == xterm* ]]; then
 | 
			
		||||
  unset TMOUT
 | 
			
		||||
 | 
			
		||||
  precmd () {
 | 
			
		||||
    print -Pn  "\033]0;%n@%m %~\007"
 | 
			
		||||
    #print -Pn "\033]0;%n@%m%#  %~ %l  %w :: %T\a" ## or use this
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  preexec () {
 | 
			
		||||
    print -Pn "\033]0;%n@%m <$1> %~\007"
 | 
			
		||||
    #print -Pn "\033]0;%n@%m%#  <$1>  %~ %l  %w :: %T\a" ## or use this
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
fi
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user