X-Spam-Check-By: sourceware.org
Date: Thu, 4 Jan 2007 16:42:59 -0500 (EST)
From: Igor Peshansky <pechtcha@cs.nyu.edu>
Reply-To: cygwin@cygwin.com
To: Christian Franke <Christian.Franke@t-online.de>
cc: cygwin@cygwin.com
Subject: Re: Two short scripts for Cygwin-Windows interoperation
In-Reply-To: <459D5852.8010407@t-online.de>
Message-ID: <Pine.GSO.4.63.0701041641350.15041@access1.cims.nyu.edu>
References: <loom.20070104T172439-137@post.gmane.org>  <Pine.GSO.4.63.0701041220120.15041@access1.cims.nyu.edu> <459D5852.8010407@t-online.de>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
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 Thu, 4 Jan 2007, Christian Franke wrote:

> Igor Peshansky wrote:
> > ...
> > The Desktop path can be obtained in a general way by "`cygpath -uD`".
> > Unfortunately, there is no such ready shortcut for "My Documents",
> > though "`cygpath -uH`/$USER/My Documents" should work for most
> > installations of the English versions of Windows.
>
> The function SHGetSpecialFolderLocation() used by cygpath obtains (most
> of?) these pathnames from the registry.
>
> To retrieve the cygwin path of "My Documents" folder, use:
>
> $ cygpath -u "$(cat /proc/registry/HKEY_CURRENT_USER/Software/\
> Microsoft/Windows/CurrentVersion/Explorer/Shell\ Folders/Personal)"
>
> This works also on non-English XP.
> It should also work on Vista (where ugly "\Documents and
> Settings\USER\My Documents" is finally replaced by
> "\Users\USER\Documents" ;-)

The point I was making was that maybe we could add another option to
cygpath to retrieve the "My Documents" path...  Opinions?
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha@cs.nyu.edu | igor@watson.ibm.com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Freedom is just another word for "nothing left to lose"...  -- Janis Joplin

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

