r*****o 发帖数: 28 | 1 In my .cshrc, I have a alias setproj = source ~/.setproj
and in .setproj, I have the following:
...
set path = (/proj/newpath $path)
newgrp projgroup
But when I run 'setproj' in CSHELL, the new PATH is not added, I guess its'
because of the newgrp doee not export PATH to new shell, how do I get around
it?
Thanks! |
|
c*****t 发帖数: 1879 | 2 useradd -G groupname username
or
useradd -g groupname username
-g specify the primary (logon) group,
-G specifiy the secondary or more groups.
To change the group id to the supplementary group, use
newgrp.
P.S., study useradd well. It has most of the functions
you need to manage a user. |
|
c*****t 发帖数: 1879 | 3 A usual way of doing this is, make the directory a group directory
and mode 775 and put your friends into the same group. If
your friends are already in different groups and you wish not
to change their existing groups, you can add additional groupid
under userid and use the command "newgrp groupid" to switch
the effective group id. |
|