golang.org/x/build@v0.0.0-20240506185731-218518f32b70/gerrit/example_test.go (about) 1 // Copyright 2017 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 package gerrit_test 6 7 import ( 8 "context" 9 "fmt" 10 11 "golang.org/x/build/gerrit" 12 ) 13 14 func Example() { 15 c := gerrit.NewClient("https://go-review.googlesource.com", gerrit.NoAuth) 16 info, err := c.GetProjectInfo(context.TODO(), "go") 17 if err != nil { 18 panic(err) 19 } 20 fmt.Println(info.Description) 21 }