X-Recipient: archive-cygwin@delorie.com
X-Spam-Check-By: sourceware.org
Date: Wed, 12 Dec 2007 11:15:41 +0100
From: Corinna Vinschen <corinna-cygwin@cygwin.com>
To: cygwin@cygwin.com
Subject: Re: get cygpath to leave relative paths as relative?
Message-ID: <20071212101541.GU6618@calimero.vinschen.de>
Reply-To: cygwin@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
References: <678518.3115.qm@web53803.mail.re2.yahoo.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <678518.3115.qm@web53803.mail.re2.yahoo.com>
User-Agent: Mutt/1.5.16 (2007-06-09)
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

On Dec 11 21:25, Brent wrote:
> Corinna wrote:
> 
> >This is not always possible when converting POSIX paths to Win32 paths
> >for a couple of reasons.  One reason is that a relative path might
> >contain symlinks, another one is that a path containing .. could cross
> >mount points.  To recognize both cases extra processing is necessary
> >which might convert the path to an absolute form.
> 
> Thanks for responding.
> 
> You use qualifiers like "not always possible" and "might".  Does that imply that cygpath CAN leave relative paths as relative under certain circumstances?

If you use "..", no.

> What I am seeing is that it always converts relative paths to absolute
> paths, even in cases that are outside the scenarios that you mention.

$ cygpath -w src/gawk
src\gawk
$ cygpath -w ../corinna/src/gawk
C:\cygwin\home\corinna\src\gawk

> In particular, I have no symlinks.  But I am not sure what you mean by
> "cross mount points.  Sorry for my ignorance [...]

Didn't you read the user's manual?

  http://cygwin.com/cygwin-ug-net/cygwin-ug-net.html


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
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/

