Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Message-ID: <1052750540.3ebfb2cc9d549@webmail.imag.fr> Date: Mon, 12 May 2003 16:42:20 +0200 From: Sylvain DOT Ferriol AT imag DOT fr To: cygwin AT cygwin DOT com, Christopher Faylor Subject: Re: suggestion for cygutils - usermod (was Re: howto change home path in /etc/passwd) References: <1052749051 DOT 3ebfacfbf2d0a AT webmail DOT imag DOT fr> <20030512143314 DOT GE23680 AT redhat DOT com> In-Reply-To: <20030512143314.GE23680@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252;q=1.0 Content-Transfer-Encoding: 8bit User-Agent: Internet Messaging Program (IMP) 3.1 X-Originating-IP: 152.77.201.128 Surlignage Christopher Faylor : > The below message suggests that maybe we should have a usermod program > in cygwin. It should probably be in cygutils, I suspect. > > Anyone willing to investigate the linux version of usermod and submit it > to cygutils (assuming Chuck agrees)? > > cgf > Yes , because i don't want to create a shell doing this: grep -v $USERNAME /etc/passwd > /etc/passwd mkpasswd -l -u $USERNAME -p $HOME >> /etc/passwd sylvain > On Mon, May 12, 2003 at 10:25:49AM -0400, Igor Pechtchanski wrote: > >On Mon, 12 May 2003 Sylvain DOT Ferriol AT imag DOT fr wrote: > > > >> Surlignage Igor Pechtchanski : > >> > >> > On Mon, 12 May 2003, sferriol wrote: > >> > > >> > > hello > >> > > is there a command to change the home directory of a user in > /etc/passwd > >> > > because ssh sees this file before $HOME and i have always a error. > >> > > >> > Use an editor to edit /etc/passwd (as has been suggested). Mind the > line > >> > endings (I think). > >> > >> no my question is to do this automatically > >> because when the admin has installed cygwin on a computer, it adds users > >> and each users has to define the variable HOME, > >> but if they use ssh, they have to chang /etc/passwd too. > >> > >> i want to create a install file which update automatically /etc/passwd, > puts defaults files (bashrc, inputrc,...) > >> i see that there is the mkpasswd command but it doesn't do what i want > >> > >> do you know when /etc/passwd is created??? > >> > >> sylvain > > > >/etc/passwd is normally created (along with /etc/group) when setup runs > >the passwd-grp.sh postinstall script. The program that actually creates > >the passwd entries is called mkpasswd, and it sets the home directory to > >/home/ by default. > > > >One thing you can do is create symbolic links (or, better yet, user > >mounts) from /home/ to that user's $HOME. That way, you will > >not have to change /etc/passwd at all. > > -- > Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > Problem reports: http://cygwin.com/problems.html > Documentation: http://cygwin.com/docs.html > FAQ: http://cygwin.com/faq/ > > ------------------------------------------------- envoyé via Webmail/IMAG ! -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/