From 0d1aefb3b3b2d09eacaf92629b091207681e891a Mon Sep 17 00:00:00 2001 From: Spencer Schrock Date: Wed, 11 Dec 2024 14:00:08 -0800 Subject: [PATCH] use new gitlab managed client Signed-off-by: Spencer Schrock --- clients/gitlabrepo/branches.go | 2 +- clients/gitlabrepo/branches_test.go | 2 +- clients/gitlabrepo/checkruns.go | 2 +- clients/gitlabrepo/checkruns_test.go | 2 +- clients/gitlabrepo/client.go | 2 +- clients/gitlabrepo/client_e2e_test.go | 2 +- clients/gitlabrepo/client_test.go | 2 +- clients/gitlabrepo/commits.go | 2 +- clients/gitlabrepo/commits_test.go | 2 +- clients/gitlabrepo/contributors.go | 2 +- clients/gitlabrepo/contributors_test.go | 2 +- clients/gitlabrepo/issues.go | 2 +- clients/gitlabrepo/issues_test.go | 2 +- clients/gitlabrepo/languages.go | 2 +- clients/gitlabrepo/licenses.go | 2 +- clients/gitlabrepo/project.go | 2 +- clients/gitlabrepo/releases.go | 2 +- clients/gitlabrepo/repo.go | 2 +- clients/gitlabrepo/search.go | 2 +- clients/gitlabrepo/searchCommits.go | 2 +- clients/gitlabrepo/search_test.go | 2 +- clients/gitlabrepo/statuses.go | 2 +- clients/gitlabrepo/statuses_test.go | 2 +- clients/gitlabrepo/tarball.go | 2 +- clients/gitlabrepo/webhook.go | 2 +- clients/gitlabrepo/webhook_test.go | 2 +- clients/gitlabrepo/workflows.go | 2 +- go.mod | 2 +- go.sum | 4 ++-- 29 files changed, 30 insertions(+), 30 deletions(-) diff --git a/clients/gitlabrepo/branches.go b/clients/gitlabrepo/branches.go index 4858f67513d..9e19f1995f0 100644 --- a/clients/gitlabrepo/branches.go +++ b/clients/gitlabrepo/branches.go @@ -20,7 +20,7 @@ import ( "strings" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/branches_test.go b/clients/gitlabrepo/branches_test.go index 7e4c76da610..322df2e2ed4 100644 --- a/clients/gitlabrepo/branches_test.go +++ b/clients/gitlabrepo/branches_test.go @@ -19,7 +19,7 @@ import ( "sync" "testing" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" ) func TestGetBranches(t *testing.T) { diff --git a/clients/gitlabrepo/checkruns.go b/clients/gitlabrepo/checkruns.go index 505d1f55e66..107db3c9fc9 100644 --- a/clients/gitlabrepo/checkruns.go +++ b/clients/gitlabrepo/checkruns.go @@ -18,7 +18,7 @@ import ( "fmt" "regexp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/checkruns_test.go b/clients/gitlabrepo/checkruns_test.go index 5eb20cfc46d..244fb75891a 100644 --- a/clients/gitlabrepo/checkruns_test.go +++ b/clients/gitlabrepo/checkruns_test.go @@ -19,7 +19,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/client.go b/clients/gitlabrepo/client.go index 500a9e29830..40289969a97 100644 --- a/clients/gitlabrepo/client.go +++ b/clients/gitlabrepo/client.go @@ -24,7 +24,7 @@ import ( "os" "time" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" sce "github.com/ossf/scorecard/v5/errors" diff --git a/clients/gitlabrepo/client_e2e_test.go b/clients/gitlabrepo/client_e2e_test.go index 6949485ba22..0b77282270e 100644 --- a/clients/gitlabrepo/client_e2e_test.go +++ b/clients/gitlabrepo/client_e2e_test.go @@ -20,7 +20,7 @@ import ( . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" ) var _ = Describe("E2E TEST: gitlabrepo.commitsHandler", func() { diff --git a/clients/gitlabrepo/client_test.go b/clients/gitlabrepo/client_test.go index 2802b7617d9..c0ad5c2116b 100644 --- a/clients/gitlabrepo/client_test.go +++ b/clients/gitlabrepo/client_test.go @@ -21,7 +21,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/commits.go b/clients/gitlabrepo/commits.go index 5d5c0eff297..2ccc31fe4af 100644 --- a/clients/gitlabrepo/commits.go +++ b/clients/gitlabrepo/commits.go @@ -21,7 +21,7 @@ import ( "strings" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/commits_test.go b/clients/gitlabrepo/commits_test.go index 65f2053924e..b0a07eb27f5 100644 --- a/clients/gitlabrepo/commits_test.go +++ b/clients/gitlabrepo/commits_test.go @@ -19,7 +19,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/contributors.go b/clients/gitlabrepo/contributors.go index 8959df39055..c7e5830ba3a 100644 --- a/clients/gitlabrepo/contributors.go +++ b/clients/gitlabrepo/contributors.go @@ -19,7 +19,7 @@ import ( "strings" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/contributors_test.go b/clients/gitlabrepo/contributors_test.go index 0c020d6b47b..ace7b2e0d3c 100644 --- a/clients/gitlabrepo/contributors_test.go +++ b/clients/gitlabrepo/contributors_test.go @@ -19,7 +19,7 @@ import ( "sync" "testing" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" ) func TestContributors(t *testing.T) { diff --git a/clients/gitlabrepo/issues.go b/clients/gitlabrepo/issues.go index 564f1413060..f025af9f148 100644 --- a/clients/gitlabrepo/issues.go +++ b/clients/gitlabrepo/issues.go @@ -19,7 +19,7 @@ import ( "net/http" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/issues_test.go b/clients/gitlabrepo/issues_test.go index 59333acffb3..373cba6de97 100644 --- a/clients/gitlabrepo/issues_test.go +++ b/clients/gitlabrepo/issues_test.go @@ -22,7 +22,7 @@ import ( "time" "github.com/google/go-cmp/cmp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/languages.go b/clients/gitlabrepo/languages.go index 2837ae986eb..f840dde44f0 100644 --- a/clients/gitlabrepo/languages.go +++ b/clients/gitlabrepo/languages.go @@ -18,7 +18,7 @@ import ( "fmt" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/licenses.go b/clients/gitlabrepo/licenses.go index cd2e2857443..097f85b37a7 100644 --- a/clients/gitlabrepo/licenses.go +++ b/clients/gitlabrepo/licenses.go @@ -20,7 +20,7 @@ import ( "regexp" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/project.go b/clients/gitlabrepo/project.go index 6a9eb3b4d75..053ba002b61 100644 --- a/clients/gitlabrepo/project.go +++ b/clients/gitlabrepo/project.go @@ -19,7 +19,7 @@ import ( "sync" "time" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" ) type projectHandler struct { diff --git a/clients/gitlabrepo/releases.go b/clients/gitlabrepo/releases.go index dd9d7270aff..f53e93075b7 100644 --- a/clients/gitlabrepo/releases.go +++ b/clients/gitlabrepo/releases.go @@ -19,7 +19,7 @@ import ( "strings" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/repo.go b/clients/gitlabrepo/repo.go index c84164ec4a7..a0cc0bcd54d 100644 --- a/clients/gitlabrepo/repo.go +++ b/clients/gitlabrepo/repo.go @@ -24,7 +24,7 @@ import ( "os" "strings" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" sce "github.com/ossf/scorecard/v5/errors" diff --git a/clients/gitlabrepo/search.go b/clients/gitlabrepo/search.go index 8cfa7b712d7..6e61b3cdbd5 100644 --- a/clients/gitlabrepo/search.go +++ b/clients/gitlabrepo/search.go @@ -19,7 +19,7 @@ import ( "fmt" "strings" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/searchCommits.go b/clients/gitlabrepo/searchCommits.go index 29380cab11d..e66b74b2064 100644 --- a/clients/gitlabrepo/searchCommits.go +++ b/clients/gitlabrepo/searchCommits.go @@ -18,7 +18,7 @@ import ( "fmt" "strings" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/search_test.go b/clients/gitlabrepo/search_test.go index 59d39e7db1e..c9bde3b9f58 100644 --- a/clients/gitlabrepo/search_test.go +++ b/clients/gitlabrepo/search_test.go @@ -20,7 +20,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/statuses.go b/clients/gitlabrepo/statuses.go index f21bb1b7aaf..d99fcedb6cc 100644 --- a/clients/gitlabrepo/statuses.go +++ b/clients/gitlabrepo/statuses.go @@ -17,7 +17,7 @@ package gitlabrepo import ( "fmt" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/statuses_test.go b/clients/gitlabrepo/statuses_test.go index 57d2249c222..3dff35a7903 100644 --- a/clients/gitlabrepo/statuses_test.go +++ b/clients/gitlabrepo/statuses_test.go @@ -19,7 +19,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/tarball.go b/clients/gitlabrepo/tarball.go index 0783f6e7118..8e984b733d8 100644 --- a/clients/gitlabrepo/tarball.go +++ b/clients/gitlabrepo/tarball.go @@ -29,7 +29,7 @@ import ( "strings" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" sce "github.com/ossf/scorecard/v5/errors" ) diff --git a/clients/gitlabrepo/webhook.go b/clients/gitlabrepo/webhook.go index fef388087f4..a3b5bb00ee2 100644 --- a/clients/gitlabrepo/webhook.go +++ b/clients/gitlabrepo/webhook.go @@ -18,7 +18,7 @@ import ( "fmt" "sync" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/webhook_test.go b/clients/gitlabrepo/webhook_test.go index 7fd2da91427..e03f9fe84cb 100644 --- a/clients/gitlabrepo/webhook_test.go +++ b/clients/gitlabrepo/webhook_test.go @@ -20,7 +20,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/clients/gitlabrepo/workflows.go b/clients/gitlabrepo/workflows.go index 17d5342fa7c..700cd6234f8 100644 --- a/clients/gitlabrepo/workflows.go +++ b/clients/gitlabrepo/workflows.go @@ -18,7 +18,7 @@ import ( "fmt" "strings" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/ossf/scorecard/v5/clients" ) diff --git a/go.mod b/go.mod index 9bf86cec902..8a986756de9 100644 --- a/go.mod +++ b/go.mod @@ -46,6 +46,7 @@ require ( github.com/mcuadros/go-jsonschema-generator v0.0.0-20200330054847-ba7a369d4303 github.com/onsi/ginkgo/v2 v2.22.0 github.com/otiai10/copy v1.14.0 + gitlab.com/gitlab-org/api/client-go v0.116.0 sigs.k8s.io/release-utils v0.8.4 ) @@ -180,7 +181,6 @@ require ( github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/vbatts/tar-split v0.11.5 // indirect - github.com/xanzy/go-gitlab v0.115.0 github.com/xanzy/ssh-agent v0.3.3 // indirect github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb // indirect github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect diff --git a/go.sum b/go.sum index 10239326628..85647c00adc 100644 --- a/go.sum +++ b/go.sum @@ -772,8 +772,6 @@ github.com/vdemeester/k8s-pkg-credentialprovider v1.18.1-0.20201019120933-f1d169 github.com/vmihailenco/msgpack/v4 v4.3.12/go.mod h1:gborTTJjAo/GWTqqRjrLCn9pgNN+NXzzngzBKDPIqw4= github.com/vmihailenco/tagparser v0.1.1/go.mod h1:OeAg3pn3UbLjkWt+rN9oFYB6u/cQgqMEUPoW2WPyhdI= github.com/vmware/govmomi v0.20.3/go.mod h1:URlwyTFZX72RmxtxuaFL2Uj3fD1JTvZdx59bHWk6aFU= -github.com/xanzy/go-gitlab v0.115.0 h1:6DmtItNcVe+At/liXSgfE/DZNZrGfalQmBRmOcJjOn8= -github.com/xanzy/go-gitlab v0.115.0/go.mod h1:5XCDtM7AM6WMKmfDdOiEpyRWUqui2iS9ILfvCZ2gJ5M= github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= github.com/xanzy/ssh-agent v0.3.3/go.mod h1:6dzNDKs0J9rVPHPhaGCukekBHKqfl+L3KghI1Bc68Uw= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= @@ -794,6 +792,8 @@ github.com/zeebo/assert v1.3.0 h1:g7C04CbJuIDKNPFHmsk4hwZDO5O+kntRxzaUoNXj+IQ= github.com/zeebo/assert v1.3.0/go.mod h1:Pq9JiuJQpG8JLJdtkwrJESF0Foym2/D9XMU5ciN/wJ0= github.com/zeebo/xxh3 v1.0.2 h1:xZmwmqxHZA8AI603jOQ0tMqmBr9lPeFwGg6d+xy9DC0= github.com/zeebo/xxh3 v1.0.2/go.mod h1:5NWz9Sef7zIDm2JHfFlcQvNekmcEl9ekUZQQKCYaDcA= +gitlab.com/gitlab-org/api/client-go v0.116.0 h1:Dy534gtZPMrnm3fAcmQRMadrcoUyFO4FQ4rXlSAdHAw= +gitlab.com/gitlab-org/api/client-go v0.116.0/go.mod h1:B29OfnZklmaoiR7uHANh9jTyfWEgmXvZLVEnosw2Dx0= go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg=