mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-20 03:51:07 +02:00
Daniel Bolton: 29529: _aptitude: Complete format specifiers with the `-F' option.
This commit is contained in:
parent
73497c5f5e
commit
47347fc7d7
2 changed files with 38 additions and 2 deletions
|
@ -15,6 +15,9 @@
|
||||||
* 29523: Completion/Debian/Command/_git-buildpackage: Use "#desc:"
|
* 29523: Completion/Debian/Command/_git-buildpackage: Use "#desc:"
|
||||||
line for _git third-party add-on completion description.
|
line for _git third-party add-on completion description.
|
||||||
|
|
||||||
|
* Daniel Bolton: 29529: Completion/Debian/Command/_aptitude: Complete
|
||||||
|
format specifiers with the `-F' option.
|
||||||
|
|
||||||
2011-06-30 Frank Terbeck <ft@bewatermyfriend.org>
|
2011-06-30 Frank Terbeck <ft@bewatermyfriend.org>
|
||||||
|
|
||||||
* 29526: Functions/VCS_Info/vcs_info: Set `max-exports' early
|
* 29526: Functions/VCS_Info/vcs_info: Set `max-exports' early
|
||||||
|
@ -15074,5 +15077,5 @@
|
||||||
|
|
||||||
*****************************************************
|
*****************************************************
|
||||||
* This is used by the shell to define $ZSH_PATCHLEVEL
|
* This is used by the shell to define $ZSH_PATCHLEVEL
|
||||||
* $Revision: 1.5388 $
|
* $Revision: 1.5389 $
|
||||||
*****************************************************
|
*****************************************************
|
||||||
|
|
|
@ -13,6 +13,39 @@ ${${(M)${(f)"$(</etc/apt/sources.list)"}\
|
||||||
#}}}
|
#}}}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Helper function for -F / --display-format
|
||||||
|
function _aptitude_format_strings() {
|
||||||
|
_values -s , 'format string' \
|
||||||
|
'%%[Literal %]' \
|
||||||
|
'%#number[Parameter replacement]' \
|
||||||
|
'%a[Action flag]' \
|
||||||
|
'%A[Action]' \
|
||||||
|
'%B[Broken count]' \
|
||||||
|
'%c[Current state flag]' \
|
||||||
|
'%C[Current state]' \
|
||||||
|
'%d[Description]' \
|
||||||
|
'%H[Hostname]' \
|
||||||
|
'%i[Pin priority]' \
|
||||||
|
'%I[Installed size]' \
|
||||||
|
'%m[Maintainer]' \
|
||||||
|
'%M[Automatic flag]' \
|
||||||
|
'%n[Program version]' \
|
||||||
|
'%N[Program name]' \
|
||||||
|
'%o[Download size]' \
|
||||||
|
'%p[Package name]' \
|
||||||
|
'%P[Priority]' \
|
||||||
|
'%r[Reverse depends count]' \
|
||||||
|
'%R[Abbreviated priority]' \
|
||||||
|
'%s[Section]' \
|
||||||
|
'%S[Trust status]' \
|
||||||
|
'%t[Archive]' \
|
||||||
|
'%T[Tagged]' \
|
||||||
|
'%u[Disk usage change]' \
|
||||||
|
'%v[Current version]' \
|
||||||
|
'%V[Candidate version]' \
|
||||||
|
'%Z[Size change]'
|
||||||
|
}
|
||||||
|
|
||||||
_arguments -C \
|
_arguments -C \
|
||||||
'(- 1 *)'{-h,--help}'[display help information]' \
|
'(- 1 *)'{-h,--help}'[display help information]' \
|
||||||
'(- 1 *)--version[display version information]' \
|
'(- 1 *)--version[display version information]' \
|
||||||
|
@ -20,7 +53,7 @@ _arguments -C \
|
||||||
'(-d --download-only)'{-d,--download-only}"[just download packages - don\'t install]" \
|
'(-d --download-only)'{-d,--download-only}"[just download packages - don\'t install]" \
|
||||||
'(-P --prompt)'{-P,--prompt}'[always display a prompt]' \
|
'(-P --prompt)'{-P,--prompt}'[always display a prompt]' \
|
||||||
'(-y --assume-yes)'{-y,--assume-yes}'[assume yes answer to questions]' \
|
'(-y --assume-yes)'{-y,--assume-yes}'[assume yes answer to questions]' \
|
||||||
'(-F --display-format)'{-F,--display-format}'[specify output format for search command]:format' \
|
'(-F --display-format)'{-F,--display-format}'[specify output format for search command]:format:_aptitude_format_strings' \
|
||||||
'(-O --sort)'{-O,--sort}'[specify sort order]:sort order:()' \
|
'(-O --sort)'{-O,--sort}'[specify sort order]:sort order:()' \
|
||||||
'(-w --width)'{-w,--width}'[specify output width]:width' \
|
'(-w --width)'{-w,--width}'[specify output width]:width' \
|
||||||
'-f[aggressivley try to fix dependencies of broken packages]' \
|
'-f[aggressivley try to fix dependencies of broken packages]' \
|
||||||
|
|
Loading…
Reference in a new issue