@@ -135,7 +135,7 @@ func (GitLabProvider) GetBookmarks(ctx context.Context, user, ref string, token
135135 if ref == "" {
136136 ref = "HEAD"
137137 }
138- f , _ , err := c .RepositoryFiles .GetFile (user + "/" + RepoName , "bookmarks.txt" , & gitlab.GetFileOptions {Ref : gitlab .String (ref )})
138+ f , _ , err := c .RepositoryFiles .GetFile (user + "/" + RepoName , "bookmarks.txt" , & gitlab.GetFileOptions {Ref : gitlab .Ptr (ref )})
139139 if err != nil {
140140 if errors .Is (err , gitlab .ErrNotFound ) {
141141 return "" , "" , nil
@@ -188,12 +188,12 @@ func (GitLabProvider) UpdateBookmarks(ctx context.Context, user string, token *o
188188 }
189189 }
190190 opt := & gitlab.UpdateFileOptions {
191- Branch : gitlab .String (branch ),
192- Content : gitlab .String (text ),
193- AuthorEmail : gitlab .String ("Gobookmarks@arran.net.au" ),
194- AuthorName : gitlab .String ("Gobookmarks" ),
195- LastCommitID : gitlab .String (expectSHA ),
196- CommitMessage : gitlab .String ("Auto change from web" ),
191+ Branch : gitlab .Ptr (branch ),
192+ Content : gitlab .Ptr (text ),
193+ AuthorEmail : gitlab .Ptr ("Gobookmarks@arran.net.au" ),
194+ AuthorName : gitlab .Ptr ("Gobookmarks" ),
195+ LastCommitID : gitlab .Ptr (expectSHA ),
196+ CommitMessage : gitlab .Ptr ("Auto change from web" ),
197197 }
198198 _ , _ , err = c .RepositoryFiles .UpdateFile (user + "/" + RepoName , "bookmarks.txt" , opt )
199199 if err != nil {
@@ -228,11 +228,11 @@ func (GitLabProvider) CreateBookmarks(ctx context.Context, user string, token *o
228228 }
229229 }
230230 opt := & gitlab.CreateFileOptions {
231- Branch : gitlab .String (branch ),
232- Content : gitlab .String (text ),
233- AuthorEmail : gitlab .String ("Gobookmarks@arran.net.au" ),
234- AuthorName : gitlab .String ("Gobookmarks" ),
235- CommitMessage : gitlab .String ("Auto create from web" ),
231+ Branch : gitlab .Ptr (branch ),
232+ Content : gitlab .Ptr (text ),
233+ AuthorEmail : gitlab .Ptr ("Gobookmarks@arran.net.au" ),
234+ AuthorName : gitlab .Ptr ("Gobookmarks" ),
235+ CommitMessage : gitlab .Ptr ("Auto create from web" ),
236236 }
237237 _ , _ , err = c .RepositoryFiles .CreateFile (user + "/" + RepoName , "bookmarks.txt" , opt )
238238 if err != nil {
@@ -256,9 +256,9 @@ func (p GitLabProvider) CreateRepo(ctx context.Context, user string, token *oaut
256256 }
257257 RepoName = name
258258 _ , _ , err = c .Projects .CreateProject (& gitlab.CreateProjectOptions {
259- Name : gitlab .String (RepoName ),
260- Description : gitlab .String ("Personal bookmarks" ),
261- Visibility : gitlab .Visibility (gitlab .PrivateVisibility ),
259+ Name : gitlab .Ptr (RepoName ),
260+ Description : gitlab .Ptr ("Personal bookmarks" ),
261+ Visibility : gitlab .Ptr (gitlab .PrivateVisibility ),
262262 InitializeWithReadme : gitlab .Ptr (true ),
263263 })
264264 return err
0 commit comments