delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2007/05/20/13:25:34

X-Spam-Check-By: sourceware.org
To: cygwin AT cygwin DOT com
From: Thorsten Kampe <thorsten AT thorstenkampe DOT de>
Subject: Re: How to uniformly point to the root of a drive?
Date: Sun, 20 May 2007 18:23:37 +0100
Lines: 26
Message-ID: <f2q06g$fj$2@sea.gmane.org>
References: <f2por8$as9$1 AT sea DOT gmane DOT org> <46506BA1 DOT C3502CCD AT dessent DOT net> <0a3801c79af6$c32395b0$2e08a8c0 AT CAM DOT ARTIMI DOT COM> <46507312 DOT 2EDBD2A5 AT dessent DOT net> <0a3901c79afa$41cf13a0$2e08a8c0 AT CAM DOT ARTIMI DOT COM> <46507611 DOT 2E1DFFE0 AT dessent DOT net> <20070520163647 DOT GB9211 AT ednor DOT casa DOT cgf DOT cx>
Mime-Version: 1.0
User-Agent: MicroPlanet-Gravity/2.70.2067
X-IsSubscribed: yes
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

* Christopher Faylor (Sun, 20 May 2007 12:36:47 -0400)
> On Sun, May 20, 2007 at 09:23:45AM -0700, Brian Dessent wrote:
> >Dave Korn wrote:
> >>I'm not sure exactly what Thorsten is looking for in his original
> >>question, so I don't know if it's relevant here or not, but it might be
> >>useful for a portable installation to have a way to detect the drive
> >>letter so as to be able to (re)assign the mountpoints (e.g.  from
> >>Cygwin.bat) before starting up a shell or other cygwin app.  USB stick
> >>drive letters change very often...
> >
> >Yes, there is a very real need for that kind of adjustment in such a
> >situation, but you'd have to do it using native/batch scripting since
> >trying to start a bash shell with /usr pointing off into empty space
> >will probably not end well.  Since the question seemed to be looking
> >for the POSIX form of the rootdir I assumed that the mount tables had
> >already been frobbed.
> 
> Except that he mentioned /cygdrive/?  which doesn't require a root
> directory.
> 
> I assumed that he was actually looking for a way to figure out where he
> was running from so that he could set up the mount table.

The mount table is already set from a batch (4NT) script. I can refer 
to that quite easily with something like "set usb=%@left[2,%
_cmdspec]" and then using %usb.


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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019