[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: dired-mode doesn't work with -F switch to ls
From: |
Eli Zaretskii |
Subject: |
Re: dired-mode doesn't work with -F switch to ls |
Date: |
Fri, 06 Oct 2006 11:46:01 +0200 |
> From: Krishnakumar B <address@hidden>
> Date: Thu, 05 Oct 2006 21:20:27 -0500
>
> With the following in my .emacs:
>
> (setq dired-listing-switches "-alF")
>
> if I open a dired buffer, and try to visit an executable file (say a batch
> file), I get the following error:
>
> dired-get-file-for-visit: File no longer exists; type `g' to update dired
> buffer
>
> Which is not true, i.e., the file exists. I think that Emacs is somehow
> confused by the trailing * in the dired listing for executable files, and
> tries to open a file with a * at the end. Stack trace when error occurs is
> below:
>
> signal(error ("File no longer exists; type `g' to update dired buffer"))
> error("File no longer exists; type `g' to update dired buffer")
> dired-get-file-for-visit()
> dired-advertised-find-file()
> call-interactively(dired-advertised-find-file)
>
> This used to work in GNU Emacs. I am able to reproduce it with emacs -q
> and manually setting the dired-listing-switches variable. For example, a
> file rename also fails with the following error:
>
> Thu Oct 05 21:12:01 2006 Buffer `bin'
> Move `c:/Tools/bin/ls.exe*' to `c:/Tools/bin/gls.exe' failed:
> (file-error Renaming invalid argument c:/Tools/bin/ls.exe*
> c:/Tools/bin/gls.exe)
>
> I don't have Cygwin installed, but I do have UnixUtils installed (which
> ships with GNU ls). But I think the default configuration of GNU Emacs on
> Windows doesn't use the insert-directory-program since
> ls-lisp-use-insert-directory-program is nil by default. I also checked the
> behaviour after renaming ls to gls, but the error persists. So I think
> that it's a bug in the lisp emulation of ls (or somewhere in dired-mode).
It's not a bug in ls-lisp.el, it's a well-known limitation: ls-lisp
doesn't support the -F switch yet.
And yes, if ls-lisp-use-insert-directory-program is nil, Emacs on
Windows will not use ls.exe, even if you do have it.