delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-2.2 required=5.0 tests=AWL,BAYES_00 |
X-Spam-Check-By: | sourceware.org |
Message-ID: | <4A95AA6A.9010909@bopp.net> |
Date: | Wed, 26 Aug 2009 16:34:34 -0500 |
From: | Jeremy Bopp <jeremy AT bopp DOT net> |
User-Agent: | Thunderbird 2.0.0.23 (Windows/20090812) |
MIME-Version: | 1.0 |
To: | cygwin AT cygwin DOT com |
Subject: | Re: Changing HOME for PERL |
References: | <CC93624851A47D42AFD22FB06BCD2D9A0234B8A7 AT CORPUSMX80B DOT corp DOT emc DOT com> <4A959537 DOT 7020900 AT bopp DOT net> <CC93624851A47D42AFD22FB06BCD2D9A0234B90D AT CORPUSMX80B DOT corp DOT emc DOT com> |
In-Reply-To: | <CC93624851A47D42AFD22FB06BCD2D9A0234B90D@CORPUSMX80B.corp.emc.com> |
X-IsSubscribed: | yes |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
--------------enig7A141790CA9968345BB4F052 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Please make sure to reply to the list so that others can benefit from what we discover. We can take this off list if the moderators decide this is not the appropriate forum for our discussion. Dexter_Michael AT emc DOT com wrote: > Hi Jeremy, >=20 > Thank you - I see I should elabore and include my error for a proper > solution. > I am confused as to what I should do next. >=20 > So to reverse what I have done so far I went into cygwin\etc and > replaced the modified passwd file with the original passwd file. This is good. You should be able to leave the /etc/passwd file alone. > If I remove the HOME variable in Windows, what change do I need to make > and where to get Cygwin to open at /usr/bin Your problem doesn't require that your shell drop you into /usr/bin. While it may work as a hack to solve your issue immediately, you'll likely run into more issues later on. > Yesterday I tried to run one of the Perl scripts from class with the > following SHEBANG: #!/usr/bin/perl >=20 > In order for me to fix the error (make it go away) I had to change my > SHEBANG to: > #!/cygdrive/c/PERL/BIN/perl >=20 > Here is what the error was: > dextem AT USENDEXTEML1C ~/PERL > $ ./test1-mike.pl > bash: ./test1-mike.pl: /usr/bin/perl^M: bad interpreter: Permission > denied This looks like an issue caused by DOS line endings in your script (see the ^M in the error message); however, I can't reproduce the error here even when purposely changing line endings to DOS line endings. > Using the cygdrive SHEBANG the file runs great: > dextem AT USENDEXTEML1C ~/PERL > $ ./test1-mike.pl > he he he > he he he > he he he bye The method you used to change the SheBang line could be the more important reason for the fix than the change itself, but I would need to see both versions of the file to be sure. > So what do I need to do so that I can use the Unix SHEBANG > #!/usr/bin/perl=20=20 > in the top of all my files. I prefer not the env variable solution > unless that is the only way. Something you can try before sending these files is to run d2u or dos2unix on the file which is failing: d2u test1-mike.pl That will convert all DOS line endings into Unix line endings, and that may solve your issue. -Jeremy --------------enig7A141790CA9968345BB4F052 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkqVqnAACgkQHt4KKRq6ZjfqNgCgiJ4oJpnfbp9W792YBi0n81q8 1s8An0JE8FkLoXI72+QyBXn8ET4veb4T =AFde -----END PGP SIGNATURE----- --------------enig7A141790CA9968345BB4F052--
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |