[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Following shortcuts when using tab completion with emacs on windows.

From: Drew Adams
Subject: RE: Following shortcuts when using tab completion with emacs on windows.
Date: Sat, 30 Jan 2010 08:22:45 -0800

> I would like to find a way to follow windows shortcuts (*.lnk) files
> when using tab completion.
> The package "w32-symlinks" allows emacs to follow windows shortcuts.
> Does any one know how to tie this into the tab completion so that
> links will be followed?
> The exact behavior that I would like is that when I type C-x C-f to
> open a file, then type in the name of a shortcut and press <TAB>, I
> would be taken to the linked directory and be able to choose a file.
> Basically to mimic symbolic links on POSIX.  Any link files that I do
> encounter will have been created by cygwin.
> I am using a windows installation of emacs 23.1.

In Emacs 22, if you customize (not just setq) option
`w32-symlinks-handle-shortcuts' to `t', then it should do what you want. It
works for me, at least.

In Emacs 23.1, it seems to raise an error, "wrong-type-argument stringp #<buffer

The problem is that the file-name handler kicks in for
`verify-visited-file-modtime', whose arg is a buffer, not a file name. That
leads to `w32-symlinks-parse-shortcut' being called on the buffer, which calls
`insert-file-contents' on the buffer (and it expects a file name).

I tried with the version of w32-symlinks.el here:

Perhaps the author, Francis J. Wright has a more recent version that doesn't
have this problem. (But the latest version I find on his Web site is the same as
the Emacs-Wiki version.) You might ask either Francis or Lars Hansen (who has
made the latest updates to the library) to look into the problem, assuming I'm
not the only one who sees it.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]