Fix file-name detection in Dired under -F
* lisp/files.el (insert-directory-clean): Support all the symbols appended to file names by the -F/--classify option of 'ls'. See https://lists.gnu.org/archive/html/emacs-devel/2024-07/msg00366.html for the details.
This commit is contained in:
parent
334d513220
commit
d190cb0e88
1 changed files with 2 additions and 2 deletions
|
@ -8087,8 +8087,8 @@ Valid wildcards are `*', `?', `[abc]' and `[a-z]'."
|
||||||
(end (insert-directory-adj-pos
|
(end (insert-directory-adj-pos
|
||||||
(+ beg (read (current-buffer)))
|
(+ beg (read (current-buffer)))
|
||||||
error-lines)))
|
error-lines)))
|
||||||
(if (memq (char-after end) '(?\n ?\s))
|
(if (memq (char-after end) '(?\n ?\s ?/ ?* ?@ ?% ?= ?|))
|
||||||
;; End is followed by \n or by " -> ".
|
;; End is followed by \n or by output of -F.
|
||||||
(put-text-property start end 'dired-filename t)
|
(put-text-property start end 'dired-filename t)
|
||||||
;; It seems that we can't trust ls's output as to
|
;; It seems that we can't trust ls's output as to
|
||||||
;; byte positions of filenames.
|
;; byte positions of filenames.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue