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:from:to:subject:date:message-id:mime-version :content-type:content-transfer-encoding; q=dns; s=default; b=OYJ F8iXeChODNha8q9WiWkaBJfO8Nt45rGZLnpBgyDMY+HRj7MiNtptluziEWZltL+3 t5M9AZOL18VhgnaykuhuH9phfNgEORYhZMNVb0oOKnPVXay5uLGt+FFQS9F6/AVd wr7c7YrEn05H/c9o5gk0QbajNueeCPyOPE8o4Pq8= 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:from:to:subject:date:message-id:mime-version :content-type:content-transfer-encoding; s=default; bh=kCZhJuaPf QS8i9R66lwCvXQGzAA=; b=tDT6eE1ZXpzVeU6Op8aJe9VU6Nql3Za+wU4+uR0Ta c2vdrov0eV5JD/Ne6aQJs0MSZBti/O73nG/93N4ybSgDyCBPRW/R4ZGCWRHP8Wfj CTjdmzToCGagEJxZLAXyUjAPJa/voBbZXa9m2SAYhor0OHIhVxrowGJ9BnDzH4Rm hM= 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-Virus-Found: No X-Spam-SWARE-Status: No, score=0.8 required=5.0 tests=AWL,BAYES_20,HTML_MESSAGE,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2 spammy=Commercial, Directors, Managing, observe X-HELO: mga06.intel.com X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-ExtLoop1: 1 From: "Soegtrop, Michael" To: "cygwin AT cygwin DOT com" Subject: Unexpected behavior of ~ when calling bash from a different cygwin installation Date: Fri, 15 Jun 2018 11:32:44 +0000 Message-ID: <0F7D3B1B3C4B894D824F5B822E3E5A1778800706@IRSMSX102.ger.corp.intel.com> x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiY2Q1ODcxZWEtZTRmZS00OGQwLTg3MTUtNWNmZDBmNWJlMzg2IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiRHFIYkwyN1hwM0tnTE5VYW9UQmE1a1FMcUhWSllpM1pEbkFrYVNSWExRQ3lCc3FNUzlKT0l4M05rQ2hoN1dEMiJ9 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-IsSubscribed: yes Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id w5FBYXxa028524 Dear Cygwin users, I have several Cygwin installation for different purposes (think of it as light weight VMs). I observe an unexpected behavior of ~ when I call a bash from one Cygwin from a bash of another Cygwin. The procedure is as follows: * I have a Cygwin in C:\bin\cygwinA * I start a bash via C:\bin\cygwinA\cygwin.bat * From this bash I start DOS batch file which first sets up a new Cygwin under C:\bin\cygwinB with a well-defined set of packages * The same batch file then starts a bash from CygwinB via C:\bin\cygwinB\bin\bash --login /cygdrive/c/bin/cygwinB/somefolder/somescript.sh When I dump various paths from somescript.sh I get: * echo "$(cygpath -a -w /)" => C:\bin\cygwinB * echo "$(cygpath -a -w .)" => C:\bin\cygwinA\home\ * echo "$(cygpath -a -w ~)" => C:\bin\cygwinA\home\ The first two are expected, but the last one is unexpected. I would have expected C:\bin\cygwinB\home\. I don't understand why / is in cygwinB but ~ in cygwinA. Best regards, Michael Intel Deutschland GmbH Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany Tel: +49 89 99 8853-0, www.intel.de Managing Directors: Christin Eisenschmid, Christian Lamprechter Chairperson of the Supervisory Board: Nicole Lau Registered Office: Munich Commercial Register: Amtsgericht Muenchen HRB 186928 -- 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