This section describes how to use the
with-editor library outside of
Magit to teach another package how to have its child processes call
home, just like Magit does. You don’t need to know any of this just
to create commits using Magit. You can also ignore this if you use
with-editor outside of Magit, but only as an end-user.
For information about interactive use and options that affect both interactive and non-interactive use, see Using the With-Editor package.
This macro arranges for the
emacsclient or the sleeping editor to be
used as the editor of child processes, effectively teaching them to
call home to the current Emacs instance when they require that the
user edits a file.
This is done by establishing a local binding for
and changing the value of the
EDITOR environment variable in that
scope. This affects all (asynchronous) processes started by forms
(dynamically) inside BODY.
If BODY begins with a literal string, then that variable is set
This macro is like
with-editor instead that the ENVVAR argument is
required and that it is evaluated at run-time.
This function is like
set-process-filter but ensures that adding the
new FILTER does not remove the
with-editor-process-filter. This is
done by wrapping the two filter functions using a lambda, which
becomes the actual filter. It calls
t as NO-STANDARD-FILTER. Then it calls FILTER.