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 content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Subject: RE: Patch to /etc/profile to deal with $HOME with a space Date: Tue, 30 Nov 2004 13:00:35 -0500 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: From: "Harig, Mark" To: "William R. Knox" , X-IsSubscribed: yes Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id iAUI0ssY007877 1. Thank you for the patch file. 2. More fundamentally, this is a problem in /etc/defaults/etc/profile, instead of with /etc/profile. 3. This file belongs to the 'base-files' package: $ /usr/bin/cygcheck -f /etc/defaults/etc/profile base-files-3.1-4 4. This problem could be reported to Bugzilla, with a patch file attachment. Please see http://sourceware.org/bugzilla/enter_bug.cgi?product=cygwin and select 'Cygwin Applications' as the Component. After you have entered the Summary and Description, revisit the Bugzilla report, and click on the 'Create new attachment' link. It will allow you to attach a patch file, and select that type of file. --- Please do not reply to me. Please do not include my email address in any replies to the Cygwin mailing list. > -----Original Message----- > From: William R. Knox > Sent: Tuesday, November 30, 2004 12:38 PM > Subject: Patch to /etc/profile to deal with $HOME with a space > > > I have just set up Cygwin, and noticed that my default home > was under my > "Documents and Settings" directory (not yet having run > mkpasswd). However, > the /etc/profile setup which tries to only create the warning message > about running mkpasswd and mkgroup once can't deal with a > HOME environment > variable with a space in it. Here is a patch to allow that to work: > > --- /etc/profile 2004-11-26 14:53:34.477082000 -0500 > +++ /etc/profile 2004-11-30 11:22:32.175340300 -0500 > @@ -194,10 +194,10 @@ > echo "and can be safely ignored." > > # only display the above once > - cp -f /etc/group ${HOME}/group.mkgroup_l_d \ > + cp -f /etc/group "${HOME}/group.mkgroup_l_d" \ > && ( [ -w /etc/group ] || chmod --silent a+w /etc/group ; )\ > - && sed -e 's/^mkgroup_l_d/mkgroup-l-d/' > ${HOME}/group.mkgroup_l_d > /etc/grou > p \ > + && sed -e 's/^mkgroup_l_d/mkgroup-l-d/' > "${HOME}/group.mkgroup_l_d" > /etc/gr > oup \ > && chmod --silent --reference=/etc/passwd /etc/group > - rm -f ${HOME}/group.mkgroup_l_d > + rm -f "${HOME}/group.mkgroup_l_d" > ;; > esac > -------- -- 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/