| delorie.com/archives/browse.cgi | search |
| 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:references:date:in-reply-to | |
| :message-id:mime-version:content-type:content-transfer-encoding; | |
| q=dns; s=default; b=lANPtj/3AXL95Ho2VDHkZzC12Qz+DydqAGs+nDYSl/W | |
| CmFX3qJNcUK0P0zJOyOOB61Md2HBEa4FF/4kAKWopWC9x2/7KG5RuFjBPL22aTR1 | |
| QZCQkYuEvyRCA7OLW/sZXCWVykmt1ZHy7xDCakb6Tdib+MMgfsqFN7nPE6r3dxyI | |
| = | |
| 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:references:date:in-reply-to | |
| :message-id:mime-version:content-type:content-transfer-encoding; | |
| s=default; bh=XiDmCUlBAcg3sM32xbMminNAcVE=; b=EE1FW/8l5nnL1/+d7 | |
| J1xIomtPbSPTqJwsusXe/WbDNkFzaapGCjDLG6tmkV3Oil61HLiKtxTPKouKx/uu | |
| R24DpFhMeixmYi9Zb9qqCFXo4Tv0yfIq5SAPSs+jevGp0GjjhQgLVIShNPk4TFTu | |
| P6UHZ1/U/74g4yJCuzxURpOyUE= | |
| Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
| List-Id: | <cygwin.cygwin.com> |
| List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
| List-Archive: | <http://sourceware.org/ml/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
| 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=-1.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 |
| X-HELO: | mail-in-05.arcor-online.net |
| X-DKIM: | Sendmail DKIM Filter v2.8.2 mail-in-01.arcor-online.net 3pDDpt3BW1zFQZJ |
| From: | Achim Gratz <Stromeko AT nexgo DOT de> |
| To: | cygwin AT cygwin DOT com |
| Subject: | Re: Ability to specify /cygdrive mount value in setup |
| References: | <20151125140420 DOT 12415 AT web008 DOT roc2 DOT bluetie DOT com> <1447966985 DOT 20151125232513 AT yandex DOT ru> <56562105 DOT 5040500 AT gmail DOT com> <6CF2FC1279D0844C9357664DC5A08BA21BC3C3B8 AT msgb09 DOT nih DOT gov> <20151126134221 DOT GN2755 AT calimero DOT vinschen DOT de> <87mvtnucw6 DOT fsf AT Rainer DOT invalid> <20151206141054 DOT GC17433 AT calimero DOT vinschen DOT de> <87egeztzwg DOT fsf AT Rainer DOT invalid> |
| Date: | Sun, 06 Dec 2015 18:12:17 +0100 |
| In-Reply-To: | <87egeztzwg.fsf@Rainer.invalid> (Achim Gratz's message of "Sun, 06 Dec 2015 15:28:15 +0100") |
| Message-ID: | <874mfvtsb2.fsf@Rainer.invalid> |
| User-Agent: | Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
| MIME-Version: | 1.0 |
| X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id tB6HCgFF000827 |
Achim Gratz writes:
> I need cygpath to get the system directory (hint: it need not be in
> C:\Windows\System32) and cygpath delivers that directory with the
> cygdrive prefix and not /proc/cygpath prepended. IÂ wouldn't mind if all
> those special directories would also be available via /proc/<whatever>,
> which means I wouldn't even need to fork cygpath for getting there.
This will get me the correct path to link to, but I still think it's
unnecessarily ugly (and took a while to cover all the possibilities of
not-so-well-formed cygdrive prefixes):
--8<---------------cut here---------------start------------->8---
CYGDRIVE="$(/usr/bin/cygpath -u C:)"
WINETC="$(/usr/bin/cygpath -S -u)/drivers/etc"
WINETC="/proc/cygdrive/${WINETC#${CYGDRIVE%c}}"
--8<---------------cut here---------------end--------------->8---
versus the hypothetical
--8<---------------cut here---------------start------------->8---
WINETC="$(/usr/bin/cygpath -S -U)/drivers/etc"
--8<---------------cut here---------------end--------------->8---
BTW, the path comprising the cygdrive prefix probably needs to be
sanitized to avoid things like
--8<---------------cut here---------------start------------->8---
$ mount -c /bla//fasel////blum//////
--8<---------------cut here---------------end--------------->8---
leaking into the wild.
Regards,
Achim.
--
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+
Factory and User Sound Singles for Waldorf Q+, Q and microQ:
http://Synth.Stromeko.net/Downloads.html#WaldorfSounds
--
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
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |