4

In Magit, how can I cancel a git process that is taking too long?

If I did something like git push from a terminal, I could press control-C to cancel. How can I do this from Magit?

  • M-x list-processes, select the process to be killed (with the cursor or the mouse), press the letter d to delete the process at point. – lawlist Feb 18 '16 at 3:35
5

You can use M-x magit-process-kill in the Magit process buffer ($, or M-x magit-process-buffer jumps to process buffer for the current repository).

magit-process-kill is an interactive Lisp closure in `magit-process.el'.

(magit-process-kill)

Kill the process at point.
4

Type $ in the Magit Status buffer to open Magit's process buffer , and then kill this buffer. Emacs will ask you whether to kill the process.

  • 3
    Or M-: (kill-process) to do so without killing the buffer. See also stackoverflow.com/q/10627289 – phils Feb 18 '16 at 11:28
  • @phils Ah, nice, I didn't know that. – lunaryorn Feb 18 '16 at 11:34
  • 4
    There is also magit-process-kill, could also be useful – npostavs Feb 18 '16 at 16:04
  • Although this does work, I don't want to lose my history of underlying git commands. – tboyce12 Feb 18 '16 at 23:30
  • @npostavs I think your comment is the best answer. If you move it to an answer then I will accept it :). Thanks everyone for the quick responses! – tboyce12 Feb 18 '16 at 23:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.