summaryrefslogtreecommitdiff
path: root/doc/lispref
diff options
context:
space:
mode:
authorPhilipp Stephani <p.stephani2@gmail.com>2018-12-17 21:47:46 +0100
committerPhilipp Stephani <phst@google.com>2018-12-22 22:10:48 +0100
commit039be4e02513e03ae465efae5694bd4e28a74dbe (patch)
tree34d43f419b279e7f652ef592332f2021b5eedc66 /doc/lispref
parentb41789f31f2355f6de8c15bbbc10cd6bf3dfe61e (diff)
downloademacs-039be4e02513e03ae465efae5694bd4e28a74dbe.tar.gz
emacs-039be4e02513e03ae465efae5694bd4e28a74dbe.tar.bz2
emacs-039be4e02513e03ae465efae5694bd4e28a74dbe.zip
Add file name handler support for 'make-process' (Bug#28691)
* src/process.c (Fmake_process): Add new keyword argument ':file-handler'. (syms_of_process) <make-process, :file-handler>: Define new symbols. * lisp/files.el (file-name-non-special): Add support for 'make-process'. * test/src/process-tests.el (make-process/file-handler/found) (make-process/file-handler/not-found) (make-process/file-handler/disable): New unit tests. (process-tests--file-handler): New helper function. * test/lisp/files-tests.el (files-tests-file-name-non-special-make-process): New unit test. * doc/lispref/files.texi (Magic File Names): Document that 'make-process' can invoke file name handlers. * doc/lispref/processes.texi (Asynchronous Processes): Document ':file-handlers' argument to 'make-process'. * etc/NEWS (Lisp Changes in Emacs 27.1): Mention new :file-handler argument for 'make-process'.
Diffstat (limited to 'doc/lispref')
-rw-r--r--doc/lispref/files.texi2
-rw-r--r--doc/lispref/processes.texi10
2 files changed, 10 insertions, 2 deletions
diff --git a/doc/lispref/files.texi b/doc/lispref/files.texi
index 5b428b6205d..d929978b6ea 100644
--- a/doc/lispref/files.texi
+++ b/doc/lispref/files.texi
@@ -3171,6 +3171,7 @@ first, before handlers for jobs such as remote file access.
@code{make-directory},
@code{make-directory-internal},
@code{make-nearby-temp-file},
+@code{make-process},
@code{make-symbolic-link},@*
@code{process-file},
@code{rename-file}, @code{set-file-acl}, @code{set-file-modes},
@@ -3227,6 +3228,7 @@ first, before handlers for jobs such as remote file access.
@code{make-auto-save-file-name},
@code{make-direc@discretionary{}{}{}tory},
@code{make-direc@discretionary{}{}{}tory-internal},
+@code{make-process},
@code{make-symbolic-link},
@code{process-file},
@code{rename-file}, @code{set-file-acl}, @code{set-file-modes},
diff --git a/doc/lispref/processes.texi b/doc/lispref/processes.texi
index 402691c6bcf..d72f5b880a2 100644
--- a/doc/lispref/processes.texi
+++ b/doc/lispref/processes.texi
@@ -696,6 +696,12 @@ non-@code{nil} value should be either a buffer or a pipe process
created with @code{make-pipe-process}, described below. If
@var{stderr} is @code{nil}, standard error is mixed with standard
output, and both are sent to @var{buffer} or @var{filter}.
+
+@item :file-handler @var{file-handler}
+If @var{file-handler} is non-@code{nil}, then look for a file name
+handler for the current buffer's @code{default-directory}, and invoke
+that file handler to make the process. If there is no such handler,
+proceed as if @var{file-handler} were @code{nil}.
@end table
The original argument list, modified with the actual connection
@@ -704,8 +710,8 @@ information, is available via the @code{process-contact} function.
The current working directory of the subprocess is set to the current
buffer's value of @code{default-directory} if that is local (as
determined by `unhandled-file-name-directory'), or "~" otherwise. If
-you want to run a process in a remote directory use
-@code{start-file-process}.
+you want to run a process in a remote directory, pass
+@code{:file-handler t} to @code{make-process}.
@end defun
@defun make-pipe-process &rest args