X-Spam-Check-By: sourceware.org Message-ID: Date: Mon, 21 May 2007 00:54:09 -0400 From: "Lev Bishop" To: cygwin AT cygwin DOT com Subject: Re: How to uniformly point to the root of a drive? In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Disposition: inline References: <20070520173616 DOT GA9531 AT ednor DOT casa DOT cgf DOT cx> Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: 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-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id l4L4sPsW001588 On 5/20/07, Karl M wrote: > Hi All... > > >From: Christopher Faylor Subject: Re: How to uniformly point to the root of > >a drive? > >Date: Sun, 20 May 2007 13:36:16 -0400 > > > >On Sun, May 20, 2007 at 01:27:05PM -0400, Christopher Faylor wrote: > > >So it sounds like Brian's method would work then wouldn't it? > > > >Does this give you what you want, too? > > > >driveroot=$(cygpath $(cygpath -wm /)/..) > > > What is the difference between "cygpath -m ..." and "cygpath -wm ..." That's easy: they're exactly the same. Now for some tricky ones: 1)what does: "cygpath -lpw '/bin/nonexistant:/usr/bin'" do? 2)what's the difference between "cygpath -m ..." and "cygpath -t mixed ..."? 3)what's the difference between: "cygpath -uuuu -t mixed -t mixed -t unix -t mixed -mmm ..." and "cygpath -m ..." Answers follow: Answers 1) $ cygpath -lpw '/bin/nonexistant:/usr/bin' ÷;C:\cygwin\bin ^ That's a divided-by symbol there. Some lack of error checking somewhere, I suppose. 2) $ cygpath -t mixed .. && cygpath -t mixed -D C:/cygwin/home/ /cygdrive/c/Documents and Settings/Lev/Desktop $ cygpath -m .. && cygpath -m -D C:/cygwin/home/ C:/Documents and Settings/Lev/Desktop Ie, they're the same for usual paths, but '-t mixed' gives a unix path for the "system information" options 3) none -- 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/