##// END OF EJS Templates
mq.el: add hook to run when finishing the edit of a patch.
Bryan O'Sullivan -
r4427:b59611e9 default
parent child Browse files
Show More
@@ -36,6 +36,11 b''
36 :type 'sexp
36 :type 'sexp
37 :group 'mercurial)
37 :group 'mercurial)
38
38
39 (defcustom mq-edit-finish-hook nil
40 "Hook run before a patch description is finished up with."
41 :type 'sexp
42 :group 'mercurial)
43
39
44
40 ;;; Internal variables.
45 ;;; Internal variables.
41
46
@@ -237,6 +242,7 b' This would become the active patch if po'
237 (unless (equal (mq-patch-info "qtop") mq-top)
242 (unless (equal (mq-patch-info "qtop") mq-top)
238 (error "Topmost patch has changed!"))
243 (error "Topmost patch has changed!"))
239 (hg-sync-buffers hg-root)
244 (hg-sync-buffers hg-root)
245 (run-hooks 'mq-edit-finish-hook)
240 (mq-refresh-internal hg-root "-m" (buffer-substring (point-min) (point-max)))
246 (mq-refresh-internal hg-root "-m" (buffer-substring (point-min) (point-max)))
241 (let ((buf mq-prev-buffer))
247 (let ((buf mq-prev-buffer))
242 (kill-buffer nil)
248 (kill-buffer nil)
General Comments 0
You need to be logged in to leave comments. Login now