about summary refs log tree commit diff
path: root/gerrit/client.go
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2021-12-09T10·49+0300
committerVincent Ambo <mail@tazj.in>2021-12-09T10·49+0300
commit24f5a642af3aa1627bbff977f0a101907a02c69f (patch)
treef1c0a6607ec9fdcdf03091fe5fbc5dabc5536a47 /gerrit/client.go
parentc67b3ba7ea769cd747ea2f43ee6d12943d599ae0 (diff)
gerrit: Use a Gerrit label instead of hashtag for autosubmit
This moves to using a Gerrit label ('Autosubmit') with boolean values
for determining whether a developer wants to have a change
automatically submitted.

See also https://cl.tvl.fyi/c/depot/+/4172
Diffstat (limited to 'gerrit/client.go')
-rw-r--r--gerrit/client.go16
1 files changed, 0 insertions, 16 deletions
diff --git a/gerrit/client.go b/gerrit/client.go
index 415871d4761e..314f97281c7e 100644
--- a/gerrit/client.go
+++ b/gerrit/client.go
@@ -26,7 +26,6 @@ type IClient interface {
 	GetChangesetURL(changeset *Changeset) string
 	SubmitChangeset(changeset *Changeset) (*Changeset, error)
 	RebaseChangeset(changeset *Changeset, ref string) (*Changeset, error)
-	RemoveTag(changeset *Changeset, tag string) (*Changeset, error)
 	ChangesetIsRebasedOnHEAD(changeset *Changeset) bool
 	SerieIsRebasedOnHEAD(serie *Serie) bool
 	FilterSeries(filter func(s *Serie) bool) []*Serie
@@ -161,21 +160,6 @@ func (c *Client) RebaseChangeset(changeset *Changeset, ref string) (*Changeset,
 	return c.fetchChangeset(changeInfo.ChangeID)
 }
 
-// RemoveTag removes the submit queue tag from a changeset and updates gerrit
-// we never add, that's something users should do in the GUI.
-func (c *Client) RemoveTag(changeset *Changeset, tag string) (*Changeset, error) {
-	hashTags := changeset.HashTags
-	newHashTags := []string{}
-	for _, hashTag := range hashTags {
-		if hashTag != tag {
-			newHashTags = append(newHashTags, hashTag)
-		}
-	}
-	// TODO: implement setting hashtags api in go-gerrit and use here
-	// https://gerrit-review.googlesource.com/Documentation/rest-api-changes.html#set-hashtags
-	return changeset, nil
-}
-
 // GetBaseURL returns the gerrit base URL
 func (c *Client) GetBaseURL() string {
 	return c.baseURL