X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type :content-transfer-encoding; q=dns; s=default; b=Hj1cjKkFplKW+f/q X2xrg/3oiTpP+ECqCpHGdDVZX80eF+wzLryGn2IBZFEl1o37wTtO93VFtaZLbccY Z/FT0YhVNJCbbJXpYy967anU2+EcBGVRTnVvPRTjrFYTYBJ3HPu1sWeA/zasOwT8 FEqPtXR2Vb4wtG/bV/nq7hx0P7c= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type :content-transfer-encoding; s=default; bh=Qat27+sAWzXHYxLOR+y/u+ YZ1+k=; b=a4ya6xbwfmgOArVhu0Kmp3P2V0gAR85L87UFPZ6RpwjiW4GxiKLkHf U2Np0SzQDiTzhGGNKDI9yY8Zduom9U29IefRlZcHsREJbrlB8lyKFqaEyDXTYep3 vX6zwDhtqzCjEKa7G+bi0rbfvAPfRM2FFoZCi6H2GevJHeA/2n8eQ= 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 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: =?ISO-8859-1?Q?No, score=1.8 required=5.0 tests=AWL,BAYES_20,FOREIGN_BODY,GIT_PATCH_2,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE autolearn=no version=3.3.2 spammy=Viren, viren, geprft, gepr=c3=bcft?= X-HELO: mout.kundenserver.de Subject: Re: error in "cygpath" behavior To: cygwin AT cygwin DOT com References: <5b88c605 DOT 1c69fb81 DOT f383 DOT a0b6 AT mx DOT google DOT com> <20180831085734 DOT GF6350 AT calimero DOT vinschen DOT de> <5f5472d0-bdee-56d0-7549-41e83d48e6bc AT gmail DOT com> From: Thomas Wolff Message-ID: Date: Sat, 1 Sep 2018 09:17:21 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-IsSubscribed: yes Am 31.08.2018 um 22:05 schrieb Eric Blake: > On 08/31/2018 02:48 PM, cyg Simple wrote: > >> >> Don't forget the possibility that '..' points to a symlink which Windows >> will not understand. >> >> $ mkdir -p /foo/baz >> $ ln -s /foo /bar >> $ cd /bar/baz >> $ cygpath -w .. > > Except .. never points to a symlink.  It always points to the physical > directory that contains the current directory (that is, /foo, not > /bar).  The shell can maintain a notion of a logical current directory > (based on whether you use 'set -P' for physical or 'set +P' for > logical; where bash defaults to +P), and in that mode, 'cd ..' behaves > logically (acting as though you are now in /bar, rather than actually > changing you to /foo).  But that still doesn't change the fact that > '..' in file name resolution never resolves to a symlink, because the > shell is merely rewriting your ".." to avoid passing it on to the > syscalls, rather than the syscalls actually knowing about logical mode. As a side-note, this is also the reason that you may be facing apparent inconsistency with path name completion, like `ls ../[TAB]` suggesting you files and directories that do not exist once you run the command. This is not cygwin-specific. --- Diese E-Mail wurde von Avast Antivirus-Software auf Viren geprüft. https://www.avast.com/antivirus -- 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