On Wednesday 05 December 2001 11:09 pm, Juan Miguel Cacho wrote:
> En Wed, Dec 05, 2001 at 02:21:37PM +0800, Deds Castillo escribio:
>
> #_ This should work if you want to preserve the existing groups and
> #_ don't want to bother typing them all up or if it's too many to type
> #_
> #_ usermod -G `id -G username | sed s/\ /,/g -`,newgroup username
>
> I think we can do without the second "-G"?

Nope, you must have them.  This is because you only want the group numbers.  
Plain 'id' will give you the uid, the group numbers and the group names.  
Test the results of 'id username' and 'id -G username' and you'll see why.  

-- 
Deds Castillo
Infiniteinfo Philippines
Hiroshima '45, Chernobyl '86, Windows 95/98/2K
_
Philippine Linux Users Group. Web site and archives at http://plug.linux.org.ph
To leave: send "unsubscribe" in the body to [EMAIL PROTECTED]

To subscribe to the Linux Newbies' List: send "subscribe" in the body to 
[EMAIL PROTECTED]

Reply via email to