mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-10-10 10:21:23 +02:00
17045: complete all files for w3m, not just *.html.
This commit is contained in:
parent
ff3e8d6ee5
commit
43a7b9b877
2 changed files with 53 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
2002-04-25 Clint Adams <clint@zsh.org>
|
||||
|
||||
* 17045: Completion/Unix/Command/_w3m: complete all files, not
|
||||
just *.html.
|
||||
|
||||
2002-04-25 Peter Stephenson <pws@csr.com>
|
||||
|
||||
* 17041: Src/Modules/zftp.c: Typos creating a data connection
|
||||
|
|
48
Completion/Unix/Command/_w3m
Normal file
48
Completion/Unix/Command/_w3m
Normal file
|
@ -0,0 +1,48 @@
|
|||
#compdef w3m
|
||||
|
||||
local curcontext="$curcontext" state line
|
||||
typeset -A opt_args
|
||||
|
||||
_arguments \
|
||||
'-t[tabwidth]:tabwidth:' \
|
||||
'-r[ignore backspace effect]' \
|
||||
'-l[preserved lines]:number of lines:' \
|
||||
'-B[load bookmark]' \
|
||||
'-bookmark:bookmark file:_files' \
|
||||
'-T[content-type]:content type:' \
|
||||
'-m[internet message mode]' \
|
||||
'-v[visual startup mode]' \
|
||||
'-M[monochrome display]' \
|
||||
'-F[automatically render frame]' \
|
||||
'(-dump_source -dump_head)-dump' \
|
||||
'-cols:column width:' \
|
||||
'(-dump -dump_head)-dump_source' \
|
||||
'(-dump -dump_source)-dump_head' \
|
||||
'+:goto line:' \
|
||||
'-num[show line number]' \
|
||||
'-no-proxy' \
|
||||
'-no-mouse' \
|
||||
'(-no-cookie)-cookie' \
|
||||
'(-cookie)-no-cookie' \
|
||||
'-no-graph' \
|
||||
'-S[squeeze multiple blank lines]' \
|
||||
'-W[toggle wrap search mode]' \
|
||||
'-X[do not use termcap init/deinit]' \
|
||||
'-o[option]:option-value:' \
|
||||
'-config:config file:_files' \
|
||||
'-debug' \
|
||||
':url:->url' && return 0
|
||||
|
||||
case $state in
|
||||
url)
|
||||
local _w3mhistory
|
||||
|
||||
if [[ -s ~/.w3m/history ]]; then
|
||||
_w3mhistory=(${(f)"$(<$HOME/.w3m/history)"})
|
||||
compadd $_w3mhistory
|
||||
fi
|
||||
|
||||
_urls -f
|
||||
;;
|
||||
|
||||
esac
|
Loading…
Reference in a new issue