On Mon, 15 Jul 2002, Angus Lees wrote: > > Something like this will work: > > grep groupname /etc/group | cut -d : -f 4 | sed s/,/ / > > That'll give you the group members as a space separated list. > > > > Won't work if groups are in NIS, LDAP, or similar. > > which is why you use getent(1), not read the files directly!
Which works better. I should have known that too, based on my recent explorations of NSS plugins. My bad. -- ----------------------------------------------------------------------- #include <disclaimer.h> Matthew Palmer, Geek In Residence http://ieee.uow.edu.au/~mjp16 -- SLUG - Sydney Linux User's Group - http://slug.org.au/ More Info: http://lists.slug.org.au/listinfo/slug