Skip to content

Commit e880388

Browse files
authored
Update gitlab dependency (#556)
1 parent 0c6aa29 commit e880388

File tree

242 files changed

+16164
-7890
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

242 files changed

+16164
-7890
lines changed

go.mod

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ require (
1717
github.com/mitchellh/go-homedir v1.1.0
1818
github.com/spf13/cobra v1.9.1
1919
github.com/spf13/viper v1.20.1
20-
github.com/xanzy/go-gitlab v0.115.0
20+
gitlab.com/gitlab-org/api/client-go v0.142.0
2121
golang.org/x/oauth2 v0.30.0
2222
gopkg.in/yaml.v2 v2.4.0
2323
)
@@ -39,7 +39,7 @@ require (
3939
github.com/google/go-github/v72 v72.0.0 // indirect
4040
github.com/google/go-querystring v1.1.0 // indirect
4141
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
42-
github.com/hashicorp/go-retryablehttp v0.7.7 // indirect
42+
github.com/hashicorp/go-retryablehttp v0.7.8 // indirect
4343
github.com/hashicorp/go-version v1.7.0 // indirect
4444
github.com/inconshreveable/mousetrap v1.1.0 // indirect
4545
github.com/kyokomi/emoji/v2 v2.2.8 // indirect
@@ -61,9 +61,9 @@ require (
6161
golang.org/x/crypto v0.37.0 // indirect
6262
golang.org/x/image v0.18.0 // indirect
6363
golang.org/x/net v0.39.0 // indirect
64-
golang.org/x/sys v0.32.0 // indirect
64+
golang.org/x/sys v0.34.0 // indirect
6565
golang.org/x/term v0.31.0 // indirect
66-
golang.org/x/text v0.24.0 // indirect
67-
golang.org/x/time v0.8.0 // indirect
66+
golang.org/x/text v0.27.0 // indirect
67+
golang.org/x/time v0.12.0 // indirect
6868
gopkg.in/yaml.v3 v3.0.1 // indirect
6969
)

go.sum

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9n
6262
github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48=
6363
github.com/hashicorp/go-hclog v1.6.3 h1:Qr2kF+eVWjTiYmU7Y31tYlP1h0q/X3Nl3tPGdaB11/k=
6464
github.com/hashicorp/go-hclog v1.6.3/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M=
65-
github.com/hashicorp/go-retryablehttp v0.7.7 h1:C8hUCYzor8PIfXHa4UrZkU4VvK8o9ISHxT2Q8+VepXU=
66-
github.com/hashicorp/go-retryablehttp v0.7.7/go.mod h1:pkQpWZeYWskR+D1tR2O5OcBFOxfA7DoAO6xtkuQnHTk=
65+
github.com/hashicorp/go-retryablehttp v0.7.8 h1:ylXZWnqa7Lhqpk0L1P1LzDtGcCR0rPVUrx/c8Unxc48=
66+
github.com/hashicorp/go-retryablehttp v0.7.8/go.mod h1:rjiScheydd+CxvumBsIrFKlx3iS0jrZ7LvzFGFmuKbw=
6767
github.com/hashicorp/go-version v1.7.0 h1:5tqGy27NaOTB8yJKUZELlFAS/LTKJkrmONwQKeRZfjY=
6868
github.com/hashicorp/go-version v1.7.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA=
6969
github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8=
@@ -133,8 +133,8 @@ github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOf
133133
github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
134134
github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8=
135135
github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU=
136-
github.com/xanzy/go-gitlab v0.115.0 h1:6DmtItNcVe+At/liXSgfE/DZNZrGfalQmBRmOcJjOn8=
137-
github.com/xanzy/go-gitlab v0.115.0/go.mod h1:5XCDtM7AM6WMKmfDdOiEpyRWUqui2iS9ILfvCZ2gJ5M=
136+
gitlab.com/gitlab-org/api/client-go v0.142.0 h1:cR8+RhDc7ooH0SiGNhgm3Nf5ZpW5D1R3DLshfAXJZmQ=
137+
gitlab.com/gitlab-org/api/client-go v0.142.0/go.mod h1:3YuWlZCirs2TTcaAzM6qNwVHB7WvV67ATb0GGpBCdlQ=
138138
go.uber.org/atomic v1.9.0 h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE=
139139
go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc=
140140
go.uber.org/multierr v1.9.0 h1:7fIwc/ZtS0q++VgcfqFDxSBZVv/Xo49/SYnDFupUwlI=
@@ -164,17 +164,17 @@ golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7w
164164
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
165165
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
166166
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
167-
golang.org/x/sys v0.32.0 h1:s77OFDvIQeibCmezSnk/q6iAfkdiQaJi4VzroCFrN20=
168-
golang.org/x/sys v0.32.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
167+
golang.org/x/sys v0.34.0 h1:H5Y5sJ2L2JRdyv7ROF1he/lPdvFsd0mJHFw2ThKHxLA=
168+
golang.org/x/sys v0.34.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
169169
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
170170
golang.org/x/term v0.31.0 h1:erwDkOK1Msy6offm1mOgvspSkslFnIGsFnxOKoufg3o=
171171
golang.org/x/term v0.31.0/go.mod h1:R4BeIy7D95HzImkxGkTW1UQTtP54tio2RyHz7PwK0aw=
172172
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
173173
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
174-
golang.org/x/text v0.24.0 h1:dd5Bzh4yt5KYA8f9CJHCP4FB4D51c2c6JvN37xJJkJ0=
175-
golang.org/x/text v0.24.0/go.mod h1:L8rBsPeo2pSS+xqN0d5u2ikmjtmoJbDBT1b7nHvFCdU=
176-
golang.org/x/time v0.8.0 h1:9i3RxcPv3PZnitoVGMPDKZSq1xW1gK1Xy3ArNOGZfEg=
177-
golang.org/x/time v0.8.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM=
174+
golang.org/x/text v0.27.0 h1:4fGWRpyh641NLlecmyl4LOe6yDdfaYNrGb2zdfo4JV4=
175+
golang.org/x/text v0.27.0/go.mod h1:1D28KMCvyooCX9hBiosv5Tz/+YLxj0j7XhWjpSUF7CU=
176+
golang.org/x/time v0.12.0 h1:ScB/8o8olJvc+CQPWrK3fPZNfh7qgwCrY0zJmoEQLSE=
177+
golang.org/x/time v0.12.0/go.mod h1:CDIdPxbZBQxdj6cxyCIdrNogrJKMJ7pr37NYpMcMDSg=
178178
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
179179
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
180180
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=

scm/gitlab.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
"strings"
1111

1212
"github.com/gabrie30/ghorg/colorlog"
13-
gitlab "github.com/xanzy/go-gitlab"
13+
gitlab "gitlab.com/gitlab-org/api/client-go"
1414
)
1515

1616
var (
@@ -121,8 +121,8 @@ func (c Gitlab) GetTopLevelGroups() ([]string, error) {
121121
PerPage: perPage,
122122
Page: 1,
123123
},
124-
TopLevelOnly: gitlab.Bool(true),
125-
AllAvailable: gitlab.Bool(true),
124+
TopLevelOnly: &[]bool{true}[0],
125+
AllAvailable: &[]bool{true}[0],
126126
}
127127

128128
for {
@@ -351,7 +351,7 @@ func (c Gitlab) GetGroupRepos(targetGroup string) ([]Repo, error) {
351351
PerPage: perPage,
352352
Page: 1,
353353
},
354-
IncludeSubGroups: gitlab.Bool(true),
354+
IncludeSubGroups: gitlab.Ptr(true),
355355
}
356356

357357
for {

scripts/local-gitlab/seeder/go.mod

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@ module gitlab-seeder
22

33
go 1.23.0
44

5-
require github.com/xanzy/go-gitlab v0.95.2
5+
require gitlab.com/gitlab-org/api/client-go v0.142.0
66

77
require (
88
github.com/google/go-querystring v1.1.0 // indirect
99
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
10-
github.com/hashicorp/go-retryablehttp v0.7.7 // indirect
11-
golang.org/x/oauth2 v0.27.0 // indirect
12-
golang.org/x/time v0.3.0 // indirect
10+
github.com/hashicorp/go-retryablehttp v0.7.8 // indirect
11+
golang.org/x/oauth2 v0.30.0 // indirect
12+
golang.org/x/time v0.12.0 // indirect
1313
)

scripts/local-gitlab/seeder/go.sum

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,33 +2,32 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c
22
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
33
github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM=
44
github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE=
5+
github.com/google/go-cmp v0.5.2 h1:X2ev0eStA3AbceY54o37/0PQ/UWqKEiiO2dKL5OPaFM=
56
github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
6-
github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38=
7-
github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
87
github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8=
98
github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU=
109
github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ=
1110
github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48=
1211
github.com/hashicorp/go-hclog v1.6.3 h1:Qr2kF+eVWjTiYmU7Y31tYlP1h0q/X3Nl3tPGdaB11/k=
1312
github.com/hashicorp/go-hclog v1.6.3/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M=
14-
github.com/hashicorp/go-retryablehttp v0.7.7 h1:C8hUCYzor8PIfXHa4UrZkU4VvK8o9ISHxT2Q8+VepXU=
15-
github.com/hashicorp/go-retryablehttp v0.7.7/go.mod h1:pkQpWZeYWskR+D1tR2O5OcBFOxfA7DoAO6xtkuQnHTk=
13+
github.com/hashicorp/go-retryablehttp v0.7.8 h1:ylXZWnqa7Lhqpk0L1P1LzDtGcCR0rPVUrx/c8Unxc48=
14+
github.com/hashicorp/go-retryablehttp v0.7.8/go.mod h1:rjiScheydd+CxvumBsIrFKlx3iS0jrZ7LvzFGFmuKbw=
1615
github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA=
1716
github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg=
1817
github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY=
1918
github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y=
2019
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
2120
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
22-
github.com/stretchr/testify v1.8.1 h1:w7B6lhMri9wdJUVmEZPGGhZzrYTPvgJArz7wNPgYKsk=
23-
github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4=
24-
github.com/xanzy/go-gitlab v0.95.2 h1:4p0IirHqEp5f0baK/aQqr4TR57IsD+8e4fuyAA1yi88=
25-
github.com/xanzy/go-gitlab v0.95.2/go.mod h1:ETg8tcj4OhrB84UEgeE8dSuV/0h4BBL1uOV/qK0vlyI=
26-
golang.org/x/oauth2 v0.27.0 h1:da9Vo7/tDv5RH/7nZDz1eMGS/q1Vv1N/7FCrBhI9I3M=
27-
golang.org/x/oauth2 v0.27.0/go.mod h1:onh5ek6nERTohokkhCD/y2cV4Do3fxFHFuAejCkRWT8=
28-
golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y=
29-
golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
30-
golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4=
31-
golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
21+
github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA=
22+
github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
23+
gitlab.com/gitlab-org/api/client-go v0.142.0 h1:cR8+RhDc7ooH0SiGNhgm3Nf5ZpW5D1R3DLshfAXJZmQ=
24+
gitlab.com/gitlab-org/api/client-go v0.142.0/go.mod h1:3YuWlZCirs2TTcaAzM6qNwVHB7WvV67ATb0GGpBCdlQ=
25+
golang.org/x/oauth2 v0.30.0 h1:dnDm7JmhM45NNpd8FDDeLhK6FwqbOf4MLCM9zb1BOHI=
26+
golang.org/x/oauth2 v0.30.0/go.mod h1:B++QgG3ZKulg6sRPGD/mqlHQs5rB3Ml9erfeDY7xKlU=
27+
golang.org/x/sys v0.34.0 h1:H5Y5sJ2L2JRdyv7ROF1he/lPdvFsd0mJHFw2ThKHxLA=
28+
golang.org/x/sys v0.34.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
29+
golang.org/x/time v0.12.0 h1:ScB/8o8olJvc+CQPWrK3fPZNfh7qgwCrY0zJmoEQLSE=
30+
golang.org/x/time v0.12.0/go.mod h1:CDIdPxbZBQxdj6cxyCIdrNogrJKMJ7pr37NYpMcMDSg=
3231
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
3332
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
3433
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=

scripts/local-gitlab/seeder/main.go

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ import (
44
"encoding/json"
55
"flag"
66
"fmt"
7-
"io/ioutil"
87
"log"
8+
"os"
99

10-
"github.com/xanzy/go-gitlab"
10+
gitlab "gitlab.com/gitlab-org/api/client-go"
1111
)
1212

1313
type Snippet struct {
@@ -70,7 +70,7 @@ func NewGitLabSeeder(token, baseURL string) (*GitLabSeeder, error) {
7070
}
7171

7272
func (g *GitLabSeeder) LoadSeedData(configPath string) error {
73-
data, err := ioutil.ReadFile(configPath)
73+
data, err := os.ReadFile(configPath)
7474
if err != nil {
7575
return fmt.Errorf("failed to read seed config: %w", err)
7676
}
@@ -98,9 +98,9 @@ func (g *GitLabSeeder) createGroup(group *Group, parentID *int) error {
9898
log.Printf("Creating group: %s", group.Name)
9999

100100
createOptions := &gitlab.CreateGroupOptions{
101-
Name: gitlab.String(group.Name),
102-
Path: gitlab.String(group.Path),
103-
Description: gitlab.String(group.Description),
101+
Name: &group.Name,
102+
Path: &group.Path,
103+
Description: &group.Description,
104104
}
105105

106106
if parentID != nil {
@@ -135,8 +135,8 @@ func (g *GitLabSeeder) createRepository(repo *Repository, namespaceID *int, grou
135135
log.Printf("Creating repository: %s", repo.Name)
136136

137137
createOptions := &gitlab.CreateProjectOptions{
138-
Name: gitlab.String(repo.Name),
139-
InitializeWithReadme: gitlab.Bool(repo.InitializeWithReadme),
138+
Name: &repo.Name,
139+
InitializeWithReadme: gitlab.Ptr(repo.InitializeWithReadme),
140140
}
141141

142142
if namespaceID != nil {
@@ -172,11 +172,11 @@ func (g *GitLabSeeder) createProjectSnippet(snippet *Snippet, projectID int, gro
172172
}
173173

174174
createOptions := &gitlab.CreateProjectSnippetOptions{
175-
Title: gitlab.String(snippet.Title),
176-
FileName: gitlab.String(snippet.FileName),
177-
Content: gitlab.String(snippet.Content),
175+
Title: &snippet.Title,
176+
FileName: &snippet.FileName,
177+
Content: &snippet.Content,
178178
Visibility: &visibility,
179-
Description: gitlab.String(snippet.Description),
179+
Description: &snippet.Description,
180180
}
181181

182182
_, _, err := g.client.ProjectSnippets.CreateSnippet(projectID, createOptions)
@@ -203,10 +203,10 @@ func (g *GitLabSeeder) createUser(user *User) error {
203203
log.Printf("Creating user: %s", user.Username)
204204

205205
createOptions := &gitlab.CreateUserOptions{
206-
Username: gitlab.String(user.Username),
207-
Email: gitlab.String(user.Email),
208-
Password: gitlab.String(user.Password),
209-
Name: gitlab.String(user.Name),
206+
Username: &user.Username,
207+
Email: &user.Email,
208+
Password: &user.Password,
209+
Name: &user.Name,
210210
}
211211

212212
createdUser, _, err := g.client.Users.CreateUser(createOptions)
@@ -231,8 +231,8 @@ func (g *GitLabSeeder) createUserRepository(repo *Repository, userID int, userna
231231

232232
// Create project for user using the correct API format
233233
createOptions := &gitlab.CreateProjectOptions{
234-
Name: gitlab.String(repo.Name),
235-
InitializeWithReadme: gitlab.Bool(repo.InitializeWithReadme),
234+
Name: &repo.Name,
235+
InitializeWithReadme: gitlab.Ptr(repo.InitializeWithReadme),
236236
}
237237

238238
// We need to get the user's namespace first
@@ -312,11 +312,11 @@ func (g *GitLabSeeder) createRootSnippet(snippet *Snippet) error {
312312
}
313313

314314
createOptions := &gitlab.CreateSnippetOptions{
315-
Title: gitlab.String(snippet.Title),
316-
FileName: gitlab.String(snippet.FileName),
317-
Content: gitlab.String(snippet.Content),
315+
Title: &snippet.Title,
316+
FileName: &snippet.FileName,
317+
Content: &snippet.Content,
318318
Visibility: &visibility,
319-
Description: gitlab.String(snippet.Description),
319+
Description: &snippet.Description,
320320
}
321321

322322
_, _, err := g.client.Snippets.CreateSnippet(createOptions)

vendor/github.com/hashicorp/go-retryablehttp/.go-version

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/hashicorp/go-retryablehttp/.golangci.yml

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/hashicorp/go-retryablehttp/CODEOWNERS

Lines changed: 13 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/hashicorp/go-retryablehttp/Makefile

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)