mirror of
				git://git.code.sf.net/p/zsh/code
				synced 2025-10-31 18:10:56 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			21 lines
		
	
	
	
		
			477 B
		
	
	
	
		
			Text
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
	
		
			477 B
		
	
	
	
		
			Text
		
	
	
	
	
	
| #compdef look
 | |
| 
 | |
| local curcontext="$curcontext" state line
 | |
| typeset -A opt_args
 | |
| 
 | |
| _arguments -C -s \
 | |
|   '-t+[termination character]:termination character:' \
 | |
|   '-f[case insensitive]' \
 | |
|   '-d[dictionary order]' \
 | |
|   ':string:->string' \
 | |
|   ':dictionary file:_files' && return 0
 | |
| 
 | |
| case "$state" in
 | |
| string)
 | |
|   if [[ -n "$PREFIX" ]]; then
 | |
|     _wanted values expl 'word prefix' compadd - $(_call_program values $words[1] $PREFIX)
 | |
|   else
 | |
|     _message -e prefixes 'word prefix'
 | |
|   fi
 | |
|   ;;
 | |
| esac
 |