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: <037701c2d083$5c3ed4f0$6b7c86d9@webdev> Reply-To: "Elfyn McBratney" From: "Elfyn McBratney" To: "cygwin" References: <000901c2d022$869cbe80$0200a8c0 AT ufo> <5 DOT 2 DOT 0 DOT 9 DOT 2 DOT 20030209080135 DOT 02d48f88 AT pop3 DOT cris DOT com> Subject: Re: cygwin symlink? bug Date: Sun, 9 Feb 2003 21:30:17 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 > Max, Trevor, > > BASH keeps an internal idea of the current working directory. In the > face of symbolic links, this internal record of the current working > directory may not be identical to that computed by the "pwd" programs > traversal-to-root algorithm. > > I use this instead of BASH's built-in pwd command: > > wd() { > WD="$(pwd)" > WDP="$(/bin/pwd)" > if [ "$WD" != "$WDP" ]; then > echo "bash: $WD"$'\n'"real: $WDP" > else > echo "$WD" > fi > } > > I use this one if I want to see the Windows form of the current working > directory, too: > > awd() { > WD="$(pwd)" > WDP="$(/bin/pwd)" > if [ "$WD" != "$WDP" ]; then > echo "bash: $WD"$'\n'"cyg: $WDP" > else > echo "cyg: $WD" > fi > echo "win: $(cygpath -w -a "$(pwd)")" > echo "mix: $(cygpath -m -a "$(pwd)")" > } > > Randall Schulz Thanks Randall, That's something new for my sandbox ;-) Ando sorry..meant to send to the list not a direct thing :::::::-) Regards, Elfyn McBratney elfyn AT exposure DOT org DOT uk www.exposure.org.uk -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/