From: Matthew <m...@uk...> - 2001-10-26 11:05:17
|
(Replied to author originally, but now to group): cut -d : -f 1,4 /etc/passwd | grep :503\$ | cut -d : -f 1 > /tmp/503s cut -d : -f 1,4 - give us the userid and gid for all password file grep :503\$ - the \$ is $ escaped which means end of line, so this gives us all users in group 503 cut -d : -f 1 - strip the gid part away M Johnny Payback wrote: > > I have a command that sends a list of my users to a > specific file and I was wondering what do I need to > change to get it to only copy users from certain > groups. Here is the command. > > cut -d : -f 1 /etc/passwd >/etc/mail/xit_customers > > How can I copy the usernames of people is say group > 503? > > Thanks, > > Johnny Payback > > __________________________________________________ > Do You Yahoo!? > Make a great connection at Yahoo! Personals. > http://personals.yahoo.com > > - > Forwarded by the Webmin mailing list at web...@li... > To remove yourself from this list, go to > http://lists.sourceforge.net/lists/listinfo/webadmin-list |