From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19843 invoked by alias); 25 Aug 2014 16:15:42 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 33053 Received: (qmail 18170 invoked from network); 25 Aug 2014 16:15:39 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 X-Biglobe-Sender: Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: Bug path completion chsh -s From: "Jun T." In-Reply-To: <140823123117.ZM23674@torch.brasslantern.com> Date: Tue, 26 Aug 2014 00:37:04 +0900 Content-Transfer-Encoding: quoted-printable Message-Id: <99E218E6-33F1-4FC2-91A9-818305EFB5C7@kba.biglobe.ne.jp> References: <53F67562.2030102@gmx.net> <140822210846.ZM22535@torch.brasslantern.com> <140823123117.ZM23674@torch.brasslantern.com> To: zsh-workers@zsh.org X-Mailer: Apple Mail (2.1878.6) X-Biglobe-Spnum: 49550 2014/08/24 04:31, Bart Schaefer wrote: > I don't have BSD handy to test with, but the > man page on MacOS claims it is using the BSD chpass. It seems BSDs have different options than Darwin. I only have FreeBSD, but checked the manpages of {Open|Net}BSD and Dragonfly on their websites. The options are different among them, so I only added options common to them. I also removed Capitalization from the descriptions of options (Specify --> specify, etc.). diff --git a/Completion/Unix/Command/_chsh = b/Completion/Unix/Command/_chsh index 97552e3..4f6453e 100644 --- a/Completion/Unix/Command/_chsh +++ b/Completion/Unix/Command/_chsh @@ -1,26 +1,35 @@ #compdef chsh chpass case $OSTYPE in -(darwin*|*bsd*) +(darwin*) _arguments : \ - '-s[Specify user login = shell]:shell:(${(Z+Cn+)"$(&/dev/null then local -a opts shells shells=3D( $(=3Dchsh -l) ) _arguments : \ - "(-)-s[Specify your login shell]:shell:($shells)" \ - "(-)--shell[Specify your login shell]:shell:($shells)" \ - "(-)-l[Print shells in /etc/shells]" \ - "(-)--list-shells[Print shells in /etc/shells]" \ - "(-)-u[Print a usage message and exit]" \ - "(-)--help[Print a usage message and exit]" \ - "(-)-v[Print version information and exit]" \ - "(-)--version[Print version information and exit]" \ + "(-)-s[specify your login shell]:shell:($shells)" \ + "(-)--shell[specify your login shell]:shell:($shells)" \ + "(-)-l[print shells in /etc/shells]" \ + "(-)--list-shells[print shells in /etc/shells]" \ + "(-)-u[print a usage message and exit]" \ + "(-)--help[print a usage message and exit]" \ + "(-)-v[print version information and exit]" \ + "(-)--version[print version information and exit]" \ "1:user name:_users" return fi