From 789ee3e1d55a86b9ce38d1374c0e01d04f97eb7d Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sat, 21 Nov 2020 15:28:52 +0100 Subject: Handle connection-local null-device and path-separator variables * doc/lispref/os.texi (System Environment): Add `path-separator' function and `null-device' variable and function. * etc/NEWS: Mention 'null-device' and 'path-separator'. Fix typos. * lisp/files-x.el (path-separator, null-device): New defuns. (Bug#3736) * lisp/net/tramp-adb.el (tramp-adb-connection-local-default-shell-variables): Rename from `tramp-adb-connection-local-default-profile'. * lisp/net/tramp-integration.el (tramp-connection-local-default-system-variables): New defvar. Add it to connection-local profiles. (tramp-connection-local-default-shell-variables): Rename from `tramp-connection-local-default-profile'. * lisp/progmodes/grep.el (grep-hello-file): New defun. (grep-compute-defaults): Use `null-device' function for remote case. Handle remote `hello-file'. Use `process-file-shell-command'. (grep,grep-expand-keywords, lgrep): Use `null-device' function for remote case. --- lisp/files-x.el | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'lisp/files-x.el') diff --git a/lisp/files-x.el b/lisp/files-x.el index 911e7ba9e3d..620a2e23f56 100644 --- a/lisp/files-x.el +++ b/lisp/files-x.el @@ -730,6 +730,16 @@ Execute BODY, and unwind connection-local variables." ;; No connection-local variables to apply. ,@body)) +;;;###autoload +(defun path-separator () + "The connection-local value of `path-separator'." + (with-connection-local-variables path-separator)) + +;;;###autoload +(defun null-device () + "The connection-local value of `null-device'." + (with-connection-local-variables null-device)) + (provide 'files-x) -- cgit v1.2.3