X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-2.8 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_NEUTRAL X-Spam-Check-By: sourceware.org Message-ID: <4F03BFAB.7030902@cornell.edu> Date: Tue, 03 Jan 2012 21:55:39 -0500 From: Ken Brown User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20111105 Thunderbird/8.0 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: Combining path components References: <33076579 DOT post AT talk DOT nabble DOT com> In-Reply-To: <33076579.post@talk.nabble.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: 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 On 1/3/2012 9:32 PM, Radly wrote: > > I just installed Cygwin, which I've used off and on since it was created. > I've been using MinGw for several months and have a .bashrc file that sets > up some environment variables for me to reduce the typing in some routine > tasks. The file has the following form, after modifying the first line from > MinGw's format to Cygwin's: > > export DD=/cygdrive/D/Common > export LL=$DD/labs > > The intent is to make $LL refer to /cygdrive/D/Common/labs. If I execute > those commands at the bash prompt, I get the desired effect: > > "echo $LL" produces "/cygdrive/D/Common/labs" > > But when I do > $ . .bashrc (or ./.bashrc, either one) > $ echo $LL > > I get > /labsrive/D/Common > > instead of > /cygdrive/D/Common/labs > > When I experiment with various paths for DD and LL, I see the following > pattern. The beginning of the DD string is overwritten with the LL string. > For instance, DD=/abcdef/ghi/jklmn; LL=/opqr yields $LL=/opqref/ghi/jklmn. Do you have CRLF line endings in your .bashrc? Try running dos2unix on it. Ken -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple