1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 10:30:25 -08:00

Add file-local-name

* doc/lispref/files.texi (Magic File Names): Add `file-local-name'.
(Unique File Names): Use it.

* etc/NEWS: Mention `file-local-name'.

* lisp/files.el (file-local-name): New defun.
(file-expand-wildcards):
* lisp/eshell/em-tramp.el (eshell/su, eshell/sudo):
* lisp/eshell/esh-ext.el (eshell-remote-command):
* lisp/eshell/esh-proc.el (eshell-gather-process-output):
* lisp/org/ob-core.el (org-babel-local-file-name):
* lisp/progmodes/gud.el (gud-common-init, gud-format-command):
* lisp/progmodes/python.el (python-shell-send-file):
* lisp/shell.el (shell):
* lisp/vc/ediff-diff.el (ediff-same-file-contents):
* lisp/vc/vc-git.el (vc-git-checkin): Use it.
This commit is contained in:
Michael Albinus 2016-11-20 16:29:47 +01:00
parent 26c4588925
commit 22946702b4
12 changed files with 42 additions and 47 deletions

View file

@ -704,13 +704,10 @@ It is based on `log-edit-mode', and has Git-specific extensions.")
;; file, to work around the limitation that command-line
;; arguments must be in the system codepage, and therefore
;; might not support the non-ASCII characters in the log
;; message.
;; message. Handle also remote files.
(if (eq system-type 'windows-nt)
(if (file-remote-p file1)
(let ((default-directory (file-name-directory file1)))
(file-remote-p
(make-nearby-temp-file "git-msg") 'localname))
(make-temp-file "git-msg")))))
(let ((default-directory (file-name-directory file1)))
(file-local-name (make-nearby-temp-file "git-msg"))))))
(cl-flet ((boolean-arg-fn
(argument)
(lambda (value) (when (equal value "yes") (list argument)))))