From 0ed3c4888466c3f03efc5a90d783637684ae53ee Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Tue, 24 Aug 2021 19:44:37 +0300 Subject: fix(tvl.el): Fix compilation warnings This fixes all compilation warnings except the one about 'tvl lacking a parent group, which we can look into later (it doesn't matter that much). Change-Id: Iaff5e7f5f251f0670afb0a47031ccf197de69818 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3408 Tested-by: BuildkiteCI Reviewed-by: sterni --- tools/emacs-pkgs/tvl/tvl.el | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'tools') diff --git a/tools/emacs-pkgs/tvl/tvl.el b/tools/emacs-pkgs/tvl/tvl.el index add72f533d..d39ba218a8 100644 --- a/tools/emacs-pkgs/tvl/tvl.el +++ b/tools/emacs-pkgs/tvl/tvl.el @@ -23,15 +23,18 @@ (defcustom tvl-gerrit-remote "origin" "Name of the git remote for gerrit" + :type '(string) :group 'tvl) (defcustom tvl-depot-path "/depot" "Location at which the TVL depot is checked out." + :type '(string) :group 'tvl) (defcustom tvl-target-branch "canon" "Branch to use to target CLs" :group 'tvl + :type '(string) :safe (lambda (_) t)) (defun tvl--gerrit-ref (target-branch &optional flags) @@ -39,7 +42,7 @@ ""))) (format "HEAD:refs/for/%s%s" target-branch flag-suffix))) -(define-suffix-command magit-gerrit-push-for-review () +(transient-define-suffix magit-gerrit-push-for-review () "Push to Gerrit for review." (interactive) (magit-push-refspecs tvl-gerrit-remote @@ -50,7 +53,7 @@ #'magit-push ["r"] (list "R" "push to Gerrit for review" #'magit-gerrit-push-for-review)) -(define-suffix-command magit-gerrit-push-wip () +(transient-define-suffix magit-gerrit-push-wip () "Push to Gerrit as a work-in-progress." (interactive) (magit-push-refspecs tvl-gerrit-remote @@ -61,7 +64,7 @@ #'magit-push ["r"] (list "W" "push to Gerrit as a work-in-progress" #'magit-gerrit-push-wip)) -(define-suffix-command magit-gerrit-submit () +(transient-define-suffix magit-gerrit-submit () "Push to Gerrit for review." (interactive) (magit-push-refspecs tvl-gerrit-remote @@ -73,7 +76,7 @@ (list "S" "push to Gerrit to submit" #'magit-gerrit-submit)) -(define-suffix-command magit-gerrit-rubberstamp () +(transient-define-suffix magit-gerrit-rubberstamp () "Push, automatically approve and submit to Gerrit. This rubberstamp operation is dangerous and should only be used in `//users'." @@ -90,7 +93,7 @@ rubberstamp operation is dangerous and should only be used in (defun tvl-depot-status () "Open the TVL monorepo in magit." (interactive) - (magit-status tvl-depot-path)) + (magit-status-setup-buffer tvl-depot-path)) (provide 'tvl) ;;; tvl.el ends here -- cgit 1.4.1