about summary refs log tree commit diff
path: root/users/glittershark/emacs.d
diff options
context:
space:
mode:
Diffstat (limited to 'users/glittershark/emacs.d')
-rw-r--r--users/glittershark/emacs.d/config.el14
1 files changed, 13 insertions, 1 deletions
diff --git a/users/glittershark/emacs.d/config.el b/users/glittershark/emacs.d/config.el
index 09d80b2acc47..76964835fa94 100644
--- a/users/glittershark/emacs.d/config.el
+++ b/users/glittershark/emacs.d/config.el
@@ -633,7 +633,19 @@
     #'magit-branch
     ["c"]
     (list "C" "Checkout Clubhouse branch" #'magit-checkout-org-clubhouse-branch))
-  )
+
+  (define-suffix-command magit-push-and-submit ()
+    (interactive)
+    (magit-push-refspecs
+     "origin" "HEAD:refs/for/master%l=Code-Review+2,publish-comments,submit"
+     nil))
+
+  (transient-append-suffix
+    #'magit-push
+    ["r"]
+
+    (list "P" "Push and submit to gerrit"
+          #'magit-push-and-submit)))
 
 ;; (defun grfn/split-window-more-sensibly (&optional window)
 ;;   (let ((window (or window (selected-window))))