Shortcuts and shortcuts do not mix [Was: cd'ing to a shortcut]

Jonathan Harris jhar@tardis.ed.ac.uk
Mon Sep 21 22:08:00 GMT 1998


Larry Smith wrote:
> 
> Windows shortcuts and cygnus symbolic links are two different
> animals. The cygnus code does its best to implement the semantics of
> Unix semantic links without help from the operating system. And as far
> as the Cygnus code is concerned, a .lnk file is just another
> binary-format file with some wierd contents. 

I don't understand why cygwin invents its own bogus file format for
softlinks when there is an existing (equally bogus) documented API for
the shortcuts used by Windows Explorer (called "Shell Links" in the MS
docs). OK, you'd have to link cygwin.dll against ole32.dll, but the
added functionality would be a big win.

In the common case of having few or no shortcuts in a directory, it
would not be noticeably slower to look for Explorer shortcuts on all
*.lnk files than the current practice of looking for cygwin softlinks on
all files with the System attribute.


> Whether your program of
> interest chooses to follow through cygnus symbolic links or Windows
> shortcut files (or both) is up to the application.

XEmacs doesn't currently understand cygwin shortcuts or Explorer
shortcut files (but neither do most Windows programs other than
Explorer  itself and the File/Open dialog [1]). There's no intrinsic
reason why it couldn't do the same magic as Explorer or cygwin.

Jonathan.

[Please cc me or xemacs-nt@xemacs.org on any replies; I don't subscribe
to gnu-win32@cygnus.com]

[1] eg try: notepad "C:\WINNT\Profiles\Default User\Start
Menu\Programs\Accessories\calculator.lnk"

-- 
Jonathan Harris  |  jhar@tardis.ed.ac.uk
London, England  |  Jonathan.Harris@symbian.com
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".



More information about the Cygwin mailing list