From: "Bakken, Luke" <Luke.Bakken@getronics.com>
To: "Garrison, Jim" <jim.garrison@athensgroup.com>, <cygwin@cygwin.com>
Subject: RE: Strange cygpath/Perl 5.8 interaction?
Date: Wed, 03 Sep 2003 20:27:00 -0000 [thread overview]
Message-ID: <407DF7D68DD30440B5CEB70ED234D1CF02DE1BB8@excuswa100.americas.unity> (raw)
lukeb@cbinfralxb ~
$ cygpath -w /c/temp | xxd
0000000: 633a 5c74 656d 700a c:\temp.
lukeb@cbinfralxb ~
$ echo "\"`cygpath -w /c/temp`\"" | xxd
0000000: 2263 3a5c 7465 6d70 220a "c:\temp".
lukeb@cbinfralxb ~
$ perl -e'$a=`cygpath -w /c/temp`;print "\"$a\""' | xxd
0000000: 2263 3a5c 7465 6d70 0a22 "c:\temp."
I'd say something was up with echo/bash, not with perl.
> -----Original Message-----
> From: Garrison, Jim [mailto:jim.garrison@athensgroup.com]
> Sent: Wednesday, September 03, 2003 1:13 PM
> To: 'cygwin@cygwin.com'
> Subject: Strange cygpath/Perl 5.8 interaction?
>
>
> In bash:
>
> $ echo "\"`cygpath -w /c/temp`\""
> "c:\temp"
>
>
> But in Perl:
>
> $a = `cygpath -w /c/temp`;
> print "|$a|";
>
> produces
>
> |c:\temp
> |
>
> I.e., Perl sees an extra \n at the end of the string. I looked at
> the source for cygpath and it doesn't seem to be adding a \n, so
> I suspect the problem is an unforeseen interaction between Cygwin
> and Perl's backtick operator. Can anyone shed light on this topic?
>
> Jim Garrison
> jhg@athensgroup.com
>
> --
> 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/
>
>
--
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/
next reply other threads:[~2003-09-03 20:27 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-09-03 20:27 Bakken, Luke [this message]
-- strict thread matches above, loose matches on Subject: below --
2003-09-03 20:13 Garrison, Jim
2003-09-03 20:30 ` Christopher Faylor
2003-09-03 20:34 ` Bill C. Riemers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=407DF7D68DD30440B5CEB70ED234D1CF02DE1BB8@excuswa100.americas.unity \
--to=luke.bakken@getronics.com \
--cc=cygwin@cygwin.com \
--cc=jim.garrison@athensgroup.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).