diff --git a/emacs/.emacs.d/config/init-git.el b/emacs/.emacs.d/config/init-git.el index f022169..ccc8ea2 100644 --- a/emacs/.emacs.d/config/init-git.el +++ b/emacs/.emacs.d/config/init-git.el @@ -85,7 +85,11 @@ Does not work on already-created pull requests." (let ((target forge--buffer-base-branch) (source forge--buffer-head-branch)) (magit-diff-range (format "%s..%s" target source)))) + (defun forge--submit-create-pullreq-after-advice (&rest args) + (when-let ((buf (magit-get-mode-buffer 'magit-diff-mode))) + (quit-window nil (get-buffer-window buf)))) (add-hook 'forge-create-pullreq-hook #'forge-diff-for-pr) + (advice-add 'forge--submit-create-pullreq :after #'forge--submit-create-pullreq-after-advice) :custom (forge-owned-accounts '((jdormit . (remote-name "jdormit")))) :general