From: Tanaka Akira <akr@jaist.ac.jp>
To: zsh-workers@sunsite.auc.dk
Subject: Re: PATCH: New completions
Date: 18 Jun 1999 22:27:13 +0900 [thread overview]
Message-ID: <rsqzp1xbpvy.fsf@crane.jaist.ac.jp> (raw)
In-Reply-To: "Kiddle, Oliver"'s message of "Fri, 18 Jun 1999 13:49:40 +0100"
In article <4FBF540FF16FD1119D9600A0C94B2B51F29E91@napier.logica.co.uk>,
"Kiddle, Oliver" <KiddleO@logica.com> writes:
> Does SunOS return solaris in $OSTYPE then - that's suprising.
Yes. It's bit tricky. But it works well because $OSTYPE is sunos4.* in
SunOS 4.x and solaris2.* in SunOS 5.x even in SunOS 5.7 --- Solaris 7.
# chown in SunOS 4.x supports "." only.
> HP/UX also
> uses a ':' so should be added to the pattern. I don't have access to it any
> more so can't tell you what it gives in $OSTYPE. I'd suggest using an if
> then else instead of the case statement as I've never seen a chown using
> anything other than . or :.
I don't know $OSTYPE in HP/UX too since I never use HP/UX.
--- Completion/User/_chown- Fri Jun 18 20:55:51 1999
+++ Completion/User/_chown Fri Jun 18 22:11:13 1999
@@ -1,10 +1,14 @@
#compdef chown chgrp
if [[ CURRENT -eq 2 || CURRENT -eq 3 && $words[CURRENT-1] = -* ]]; then
- if [[ $words[1] = chgrp ]] || compset -P '*.'; then
+ if [[ $words[1] = chgrp ]] || compset -P '*[:.]'; then
_groups
else
- compgen -u -S '.' -q
+ if [[ $OSTYPE = solaris* ]]; then
+ compgen -u -S ':' -q
+ else
+ compgen -u -S '.' -q
+ fi
fi
else
_files
--
Tanaka Akira
next prev parent reply other threads:[~1999-06-18 13:27 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-06-18 12:49 Kiddle, Oliver
1999-06-18 13:04 ` Falk Hueffner
1999-06-18 13:31 ` Tanaka Akira
1999-06-18 13:27 ` Tanaka Akira [this message]
-- strict thread matches above, loose matches on Subject: below --
2004-01-14 16:58 PATCH: new completions Oliver Kiddle
2004-01-15 7:33 ` Bart Schaefer
2004-01-15 9:41 ` Oliver Kiddle
1999-06-18 10:36 PATCH: New completions Sven Wischnowsky
1999-06-18 10:01 Sven Wischnowsky
1999-06-18 9:30 Kiddle, Oliver
1999-06-18 12:06 ` Tanaka Akira
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=rsqzp1xbpvy.fsf@crane.jaist.ac.jp \
--to=akr@jaist.ac.jp \
--cc=zsh-workers@sunsite.auc.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).