<html>
<head>
<base href="https://bugs.freedesktop.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED FIXED - zsh tab completion for pasuspender suggests -C (and other enhancements for pasuspender tab completion)"
href="https://bugs.freedesktop.org/show_bug.cgi?id=98639#c2">Comment # 2</a>
on <a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED FIXED - zsh tab completion for pasuspender suggests -C (and other enhancements for pasuspender tab completion)"
href="https://bugs.freedesktop.org/show_bug.cgi?id=98639">bug 98639</a>
from <span class="vcard"><a class="email" href="mailto:pseyfert@mathphys.fsk.uni-heidelberg.de" title="pseyfert@mathphys.fsk.uni-heidelberg.de">pseyfert@mathphys.fsk.uni-heidelberg.de</a>
</span></b>
<pre>Urgh, I realized the function can be written easier, without the ugly shift
counting:
_pasuspender_completion() {
# parenthesis expressions specify which options should not get suggested
afterwards
# e.g. after -s, help and version will not get suggested, -- remains the
only valid argument
# after "--" external commands get suggested
_arguments -C \
'(-)'{-h,--help}'[display help and exit]' \
'(-)--version[show version and exit]' \
'(-h --help --version -s --server)'{-s,--server=}'[name of server to
connect to]:host:_hosts' \
'(-)--[program]:program: _command_names -e:*::program arguments:
_normal'
}</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
<li>You are the QA Contact for the bug.</li>
</ul>
</body>
</html>