branch: elpa/dirvish commit 515b599696b262300508480aaa65ad27dc6e25d7 Author: Alex Lu <hellosimon1...@hotmail.com> Commit: Alex Lu <hellosimon1...@hotmail.com>
refactor(core): change format of preview buffer name Filename to the tail: 1. Easier for users to identify the filename's starting position. 2. Correctly retrieves the buffer file's icon. --- dirvish.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dirvish.el b/dirvish.el index 82c98965fd..5ac0908116 100644 --- a/dirvish.el +++ b/dirvish.el @@ -844,8 +844,8 @@ filename or a string with format of `dirvish-fd-bufname'." (insert "\n\nFile truncated. End of partial preview.\n"))) (setq buffer-file-name file) (goto-char (point-min)) - (rename-buffer (format "Preview: %s @DIRVISH-%s" - (file-name-nondirectory file) (dv-timestamp dv)))) + (rename-buffer (format "Preview@DIRVISH-%s :: %s" + (dv-timestamp dv) (file-name-nondirectory file)))) (condition-case err (eval `(let ,(mapcar (lambda (env) `(,(car env) ,(cdr env))) (remove '(delay-mode-hooks . t)