Function: magit-process-make-keymap

magit-process-make-keymap is a byte-compiled function defined in magit-process.el.

Signature

(magit-process-make-keymap PROCESS PARENT)

Documentation

Remap abort-minibuffers to a command that also kills PROCESS.

PARENT is used as the parent of the returned keymap.

Source Code

;; Defined in ~/.emacs.d/elpa/magit-20260411.1452/magit-process.el
(defun magit-process-make-keymap (process parent)
  "Remap `abort-minibuffers' to a command that also kills PROCESS.
PARENT is used as the parent of the returned keymap."
  (let ((cmd (lambda ()
               (interactive)
               (ignore-errors (kill-process process))
               (if (fboundp 'abort-minibuffers)
                   (abort-minibuffers)
                 (abort-recursive-edit)))))
    (define-keymap :parent parent
      "C-g" cmd
      "<remap> <abort-minibuffers>" cmd
      "<remap> <abort-recursive-edit>" cmd)))