zsh-workers
 help / color / mirror / code / Atom feed
* Re: Btw.: glob-qualifier
       [not found] <199901280754.IAA05492@beta.informatik.hu-berlin.de>
@ 1999-01-28  8:36 ` Bart Schaefer
  0 siblings, 0 replies; 3+ messages in thread
From: Bart Schaefer @ 1999-01-28  8:36 UTC (permalink / raw)
  To: Sven Wischnowsky; +Cc: zsh-workers

On Jan 28,  8:54am, Sven Wischnowsky wrote:
} Subject: Re: Btw.: glob-qualifier
}
} Bart Schaefer wrote:
} 
} > While I'm on the subject, why do we still have to use *numeric* group
} > and user IDs for the u and g qualifiers?
} 
}   echo *(u:user:g:group:)
} 
} Exists since 2.4.

Oh, good grief.  I probably even knew that, once.

} Btw. You seem to prefer the syntax with *(u(user)).

I don't prefer it, I was just scribbling an example.

} In 3.1.5 this is not taken as a list of qualifiers

Parens don't work in 3.0.5 either, ever since the (x|y) grouping syntax
got introduced.  (Now that I've actually read more than the first line
of the info entry for the `uID' glob qualifier, I see that it still
mentions parens even though they won't work.)

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Btw.: glob-qualifier
  1999-01-26 11:02 Sven Wischnowsky
@ 1999-01-28  5:35 ` Bart Schaefer
  0 siblings, 0 replies; 3+ messages in thread
From: Bart Schaefer @ 1999-01-28  5:35 UTC (permalink / raw)
  To: Sven Wischnowsky, zsh-workers

On Jan 26, 12:02pm, Sven Wischnowsky wrote:
} Subject: Btw.: glob-qualifier
}
} effect of `(o<oct>)' is to match only files whose modes (all twelve
} bits) exactly match `<oct>'. Shouldn't we either document this or
} first make it a bit more usable and then document it?

Yes.

} E.g. we could
} make it take the next four characters which should be octal digits
} or `.'s, where `.' means that in this three-bit group any value is
} accepted

Oof.  If you're going to make it usable, then REALLY make it usable.
At the risk of further abusing the already over-used parentheses, how
about (o(ug=w,o+r)) for "user and group must have exactly the write
bit set, and other must have at least r" and (o(u+x,go-w)) for "user
must have at least the execute bit set, and group and other must not
have write" and so on.

While I'm on the subject, why do we still have to use *numeric* group
and user IDs for the u and g qualifiers?  Useless for portable scripts,
except possibly for (u0).

(I know, I know, it's slow and unpleasant to do passwd and groups file
lookups, and it's undefined what to do for names that don't exist.
Grumble.)

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Btw.: glob-qualifier
@ 1999-01-26 11:02 Sven Wischnowsky
  1999-01-28  5:35 ` Bart Schaefer
  0 siblings, 1 reply; 3+ messages in thread
From: Sven Wischnowsky @ 1999-01-26 11:02 UTC (permalink / raw)
  To: zsh-workers


With all this discussion about documentation going on...

When implementing the glob-sort qualifier I first wanted to use 'o'
but then found out that this is already used and undocumented. The
effect of `(o<oct>)' is to match only files whose modes (all twelve
bits) exactly match `<oct>'. Shouldn't we either document this or
first make it a bit more usable and then document it? E.g. we could
make it take the next four characters which should be octal digits
or `.'s, where `.' means that in this three-bit group any value is
accepted (since this is a shell we should probably better use `?', or
an as yet unused character and allow the argument to have a variable
length).

Bye
 Sven

P.S.: Yes, there are still several unused characters in
      glob-qualifiers, how comes that?

--
Sven Wischnowsky                         wischnow@informatik.hu-berlin.de


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1999-01-28  8:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <199901280754.IAA05492@beta.informatik.hu-berlin.de>
1999-01-28  8:36 ` Btw.: glob-qualifier Bart Schaefer
1999-01-26 11:02 Sven Wischnowsky
1999-01-28  5:35 ` Bart Schaefer

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).