Change read-this-file to autofill with the current filename.

This commit is contained in:
kj
2025-08-29 18:06:53 -03:00
parent 87dc0ab99a
commit b7168fd349

View File

@ -88,7 +88,9 @@ If PROJECT is not specified, assume current project root."
;; Renombrar el archivo actual
(defun rename-this-file (new-name)
"Renames both current buffer and file it's visiting to NEW-NAME."
(interactive "sNew name: ")
(interactive (list (read-string "New name: "
(file-name-nondirectory
(buffer-file-name)))))
(let ((name (buffer-name))
(filename (buffer-file-name)))
(unless filename