diff options
author | Peter Stephenson <pws@users.sourceforge.net> | 2000-04-01 20:43:43 +0000 |
---|---|---|
committer | Peter Stephenson <pws@users.sourceforge.net> | 2000-04-01 20:43:43 +0000 |
commit | e025336f2f6d9f107ee1e03b9900f04af0544ba9 (patch) | |
tree | 37b0ce74587d42d4bcb024991526d2361fcdf04a /Completion/Builtins/_fc | |
parent | 20c5fbe688f24010c578c48d4b4d228f0e1a56c3 (diff) | |
download | zsh-e025336f2f6d9f107ee1e03b9900f04af0544ba9.tar.gz zsh-e025336f2f6d9f107ee1e03b9900f04af0544ba9.tar.xz zsh-e025336f2f6d9f107ee1e03b9900f04af0544ba9.zip |
Updated from list as far as 10376
Diffstat (limited to 'Completion/Builtins/_fc')
-rw-r--r-- | Completion/Builtins/_fc | 30 |
1 files changed, 25 insertions, 5 deletions
diff --git a/Completion/Builtins/_fc b/Completion/Builtins/_fc index f0d2c03fd..e97492604 100644 --- a/Completion/Builtins/_fc +++ b/Completion/Builtins/_fc @@ -1,7 +1,27 @@ -#defcomp fc +#compdef fc history -if [[ -mcurrent -1 -*e ]]; then - complist -c -elif [[ -mcurrent -1 -[ARWI]## ]]; then - _files +local fc_common + +fc_common=( \ + '(-A -R -W -I)-m[treat first argument as a pattern]' \ + '(-A -R -W -I)-r[reverse order of the commands]' \ + '(-A -R -W -I -e)-n[suppress line numbers]' \ + '(-A -R -W -I -e -f -E -i)-d[print time-stamps]' \ + '(-A -R -W -I -e -d -E -i)-f[mm/dd/yyyy format time-stamps]' \ + '(-A -R -W -I -e -d -f -i)-E[dd.mm.yyyy format time-stamps]' \ + '(-A -R -W -I -e -d -f -E)-i[yyyy-mm-dd format time-stamps]' \ + '(-A -R -W -I -e)-D[print elapsed times]' \ + '(-A -R -W -I)*::commands:_command_names -e' ) + +if [[ $words[1] = *history ]]; then + _arguments -C -s "$fc_common[@]" +else + _arguments -C -s \ + '(-A -R -W -I -e)-l[list resulting commands on stdout]' \ + '(-A -R -W -I -l -n -d -f -E -i -D)-e[specify editor to invoke]:editor to invoke:_command_names -e' \ + '(-l -m -e -r -n -d -f -E -i -D -A -W *)-R[read history from file]:history file:_files' \ + '(-l -m -e -r -n -d -f -E -i -D -R -W *)-A[append history to file]:history file:_files' \ + '(-l -m -e -r -n -d -f -E -i -D -R -A *)-W[write history to file]:history file:_files' \ + '(-l -m -e -r -n -d -f -E -i -D -A -W *)-I[read/write new events only]:history file:_files' \ + "$fc_common[@]" fi |