Bruce Korb <[EMAIL PROTECTED]> writes:

> Bob Proulx wrote:
>> 
>> How would this relate to the existing 'getent' from glibc?  There
>> appears to be a lot of overlap.  But getent seems to be more general.
>> 
>>   getent passwd bob
>>   bob:x:1000:1000:Bob Proulx,,,:/home/bob:/bin/bash
>
> 1.  you cannot get it by user id,

Yes, you can.

> 2.  you must still know that the comment is the 5th field, for example
>     and parse the line.  Thus, getent isn't any better than:
>        egrep '^bob:' /etc/passwd

Of course it is, think of NIS, LDAP, etc.

Andreas.

-- 
Andreas Schwab, SuSE Labs, [EMAIL PROTECTED]
SuSE Linux AG, Maxfeldstra�e 5, 90409 N�rnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."


_______________________________________________
Bug-coreutils mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to