Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .custom-gcl.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
version: v2.7.0
plugins:
- module: "github.com/google/go-github/v82/tools/fmtpercentv"
- module: "github.com/google/go-github/v83/tools/fmtpercentv"
path: ./tools/fmtpercentv
- module: "github.com/google/go-github/v82/tools/sliceofpointers"
- module: "github.com/google/go-github/v83/tools/sliceofpointers"
path: ./tools/sliceofpointers
- module: "github.com/google/go-github/v82/tools/structfield"
- module: "github.com/google/go-github/v83/tools/structfield"
path: ./tools/structfield
6 changes: 3 additions & 3 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -159,15 +159,15 @@ linters:
fmtpercentv:
type: module
description: Reports usage of %d or %s in format strings.
original-url: github.com/google/go-github/v82/tools/fmtpercentv
original-url: github.com/google/go-github/v83/tools/fmtpercentv
sliceofpointers:
type: module
description: Reports usage of []*string and slices of structs without pointers.
original-url: github.com/google/go-github/v82/tools/sliceofpointers
original-url: github.com/google/go-github/v83/tools/sliceofpointers
structfield:
type: module
description: Reports mismatches between Go field and JSON, URL tag names and types.
original-url: github.com/google/go-github/v82/tools/structfield
original-url: github.com/google/go-github/v83/tools/structfield
settings:
allowed-tag-names:
- ActionsCacheUsageList.RepoCacheUsage # TODO: RepoCacheUsages ?
Expand Down
21 changes: 21 additions & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
2BFL <imqksl@gmail.com>
413x <dedifferentiator@gmail.com>
6543 <6543@obermui.de>
Aaron LaBrie <bigdadbear@github.com>
Abed Kibbe <abed.kibbe@gmail.com>
Abhijit Hota <abhihota025@gmail.com>
Abhinav Gupta <mail@abhinavg.net>
Expand Down Expand Up @@ -77,6 +78,7 @@ Arda Kuyumcu <kuyumcuarda@gmail.com>
Ary <arylmoraesn@hotmail.com>
Arıl Bozoluk <arilbozoluk@hotmail.com>
Asier Marruedo <asiermarruedo@gmail.com>
Austen Stone <austenstone@github.com>
Austin Burdine <acburdine@gmail.com>
Austin Dizzy <dizzy@wow.com>
Azuka Okuleye <azuka@zatechcorp.com>
Expand All @@ -101,6 +103,7 @@ Bradley Falzon <brad@teambrad.net>
Bradley McAllister <brad.mcallister@hotmail.com>
Brandon Butler <b.butler@chia.net>
Brandon Cook <phylake@gmail.com>
Brandon Everett <bme2010@gmail.com>
Brandon Stubbs <brstubbs1@gmail.com>
Brett Kuhlman <kuhlman-labs@github.com>
Brett Logan <lindluni@github.com>
Expand Down Expand Up @@ -130,7 +133,9 @@ Christian Muehlhaeuser <muesli@gmail.com>
Christoph Jerolimov <jerolimov@gmail.com>
Christoph Sassenberg <defsprite@gmail.com>
CI Monk <ci-monk@protonmail.com>
Claus Näveke <github@naeveke.de>
Clemens W <Clemens.wijnekus@nordnet.se>
cointem <jsyin1@163.com>
Colby Williams <ColbyLWilliams@gmail.com>
Colin Misare <github.com/cmisare>
Craig Gumbley <craiggumbley@gmail.com>
Expand All @@ -157,6 +162,7 @@ Davide Zipeto <dawez1@gmail.com>
Dennis Webb <dennis@bluesentryit.com>
Derek Jobst <derekjobst@gmail.com>
DeviousLab <deviouslab@gmail.com>
Dhananjay Mishra <technicaldmcontact@gmail.com>
Dhi Aurrahman <diorahman@rockybars.com>
Diego Lapiduz <diego.lapiduz@cfpb.gov>
Diogo Vilela <be0x74a@gmail.com>
Expand Down Expand Up @@ -208,6 +214,7 @@ Glen Mailer <glenjamin@gmail.com>
Gnahz <p@oath.pl>
Google Inc.
Grachev Mikhail <work@mgrachev.com>
Gregor Jasny <gjasny@googlemail.com>
Gregory Oschwald <oschwald@gmail.com>
griffin_stewie <panterathefamilyguy@gmail.com>
guangwu <guoguangwu@magic-shield.com>
Expand All @@ -227,6 +234,7 @@ Huy Tr <kingbazoka@gmail.com>
huydx <doxuanhuy@gmail.com>
i2bskn <i2bskn@gmail.com>
Iain Steers <iainsteers@gmail.com>
Iehana Fu <wasuremono127@gmail.com>
Ikko Ashimine <eltociear@gmail.com>
Ilia Choly <ilia.choly@gmail.com>
Ioannis Georgoulas <igeorgoulas21@gmail.com>
Expand All @@ -239,6 +247,7 @@ Jake Krammer <jake.krammer1@gmail.com>
Jake Scaltreto <jake.scaltreto@circle.com>
Jake White <jake@jwhite.network>
Jameel Haffejee <RC1140@republiccommandos.co.za>
James Alseth <james@jalseth.me>
James Bowes <jbowes@repl.ca>
James Cockbain <james.cockbain@ibm.com>
James Loh <github@jloh.co>
Expand All @@ -261,6 +270,7 @@ Jesse Newland <jesse@jnewland.com>
Jihoon Chung <j.c@navercorp.com>
Jille Timmermans <jille@quis.cx>
Jimmi Dyson <jimmidyson@gmail.com>
Jiří Žižkovský <jirizizkovsky@post.cz>
Joan Saum <joan.saum@epitech.eu>
JoannaaKL <joannaakl@github.com>
Joe Tsai <joetsai@digital-static.net>
Expand Down Expand Up @@ -312,6 +322,7 @@ kyokomi <kyoko1220adword@gmail.com>
Lachlan Cooper <lachlancooper@gmail.com>
Lars Lehtonen <lars.lehtonen@gmail.com>
Laurent Verdoïa <verdoialaurent@gmail.com>
Leonard Sheng Sheng Lee <leonard.sheng.sheng.lee@gmail.com>
leopoldwang <leopold.wang@gmail.com>
Liam Galvin <liam@liam-galvin.co.uk>
Liam Stanley <liam@liam.sh>
Expand All @@ -332,6 +343,8 @@ Léo Salé <leo.sale@datadoghq.com>
M. Ryan Rigdon <mr.rigdon@gmail.com>
Magnus Kulke <mkulke@gmail.com>
Maksim Zhylinski <uzzable@gmail.com>
Manas Sivakumar <manas23601@gmail.com>
Manav Sharma <manav.acno1@gmail.com>
Manuel Bergler <manue1@github.com>
Marc Binder <marcandrebinder@gmail.com>
Marcelo Carlos <marcelo@permutive.com>
Expand All @@ -343,6 +356,8 @@ Marwan Sulaiman <marwan.sameer@gmail.com>
Masayuki Izumi <m@izum.in>
Mat Geist <matgeist@gmail.com>
Matheus Santos Araújo <wenked.matheus@yahoo.com.br>
MathewClegg <mathew.clegg@live.se>
Mathieu Sévégny <mathieu.sevegny@goto.com>
Matija Horvat <horvat2112@gmail.com>
Matin Rahmanian <itsmatinx@gmail.com>
Matt <alpmatthew@gmail.com>
Expand All @@ -356,6 +371,7 @@ Matt Simons <mattsimons@ntlworld.com>
Matthew Reidy <matthewreidy5@gmail.com>
Maxime Bury <maxime.bury@gmail.com>
Michael Meng <mmeng@lyft.com>
Michael Recachinas <mrecachinas@github.com>
Michael Spiegel <michael.m.spiegel@gmail.com>
Michael Tiller <michael.tiller@gmail.com>
Michał Glapa <michal.glapa@gmail.com>
Expand All @@ -365,6 +381,7 @@ Mike Ball <mikedball@gmail.com>
Mike Chen <mchen300@gmail.com>
Miles Crabill <miles@milescrabill.com>
Mishin Nikolai <sanduku.default@gmail.com>
Mohamad Al-Zawahreh <merchantmoh@gmail.com>
mohammad ali <2018cs92@student.uet.edu.pk>
Mohammed AlDujaili <avainer11@gmail.com>
Mohammed Nafees <hello@mnafees.me>
Expand Down Expand Up @@ -449,6 +466,7 @@ Riaje <francois@mbfr.fr>
Ricco Førgaard <ricco@fiskeben.dk>
Richard de Vries <richard.de.vries@topicus.nl>
Rob Figueiredo <robfig@yext.com>
Roger Peppe <rogpeppe@gmail.com>
Rohit Upadhyay <urohit011@gmail.com>
Rojan Dinc <rojand94@gmail.com>
Roman Wu <me@romanwu.com>
Expand Down Expand Up @@ -478,6 +496,7 @@ Sanket Payghan <sanket.payghan8@gmail.com>
Sarah Funkhouser <sarah.k.funkhouser@gmail.com>
Sarasa Kisaragi <lingsamuelgrace@gmail.com>
Sasha Melentyev <sasha@melentyev.io>
Scott Dawson <scott@daw.sn>
Sean Wang <sean@decrypted.org>
Sebastian Mandrean <sebastian.mandrean@gmail.com>
Sebastian Mæland Pedersen <sem.pedersen@stud.uis.no>
Expand Down Expand Up @@ -542,6 +561,7 @@ Victor Castell <victor@victorcastell.com>
Victor Vrantchan <vrancean+github@gmail.com>
Victory Osikwemhe <osikwemhev@gmail.com>
vikkyomkar <vikky.omkar@samsung.com>
Ville Skyttä <ville.skytta@iki.fi>
Vivek <y.vivekanand@gmail.com>
Vivek Kumar Sahu <vivekkumarsahu650@gmail.com>
Vlad Ungureanu <vladu@palantir.com>
Expand All @@ -564,6 +584,7 @@ Yumikiyo Osanai <yumios.art@gmail.com>
Yurii Soldak <ysoldak@gmail.com>
Yusef Mohamadi <yuseferi@gmail.com>
Yusuke Kuoka <ykuoka@gmail.com>
Yuto Kimura <biosugar0@gmail.com>
Zach Latta <zach@zachlatta.com>
Ze Peng <zehui.peng@circle.com>
zhouhaibing089 <zhouhaibing089@gmail.com>
Expand Down
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# go-github #

[![go-github release (latest SemVer)](https://img.shields.io/github/v/release/google/go-github?sort=semver)](https://github.com/google/go-github/releases)
[![Go Reference](https://img.shields.io/static/v1?label=godoc&message=reference&color=blue)](https://pkg.go.dev/github.com/google/go-github/v82/github)
[![Go Reference](https://img.shields.io/static/v1?label=godoc&message=reference&color=blue)](https://pkg.go.dev/github.com/google/go-github/v83/github)
[![Test Status](https://github.com/google/go-github/actions/workflows/tests.yml/badge.svg?branch=master)](https://github.com/google/go-github/actions/workflows/tests.yml)
[![Test Coverage](https://codecov.io/gh/google/go-github/branch/master/graph/badge.svg)](https://codecov.io/gh/google/go-github)
[![Discuss at go-github@googlegroups.com](https://img.shields.io/badge/discuss-go--github%40googlegroups.com-blue.svg)](https://groups.google.com/group/go-github)
Expand Down Expand Up @@ -30,36 +30,36 @@ If you're interested in using the [GraphQL API v4][], the recommended library is
go-github is compatible with modern Go releases in module mode, with Go installed:

```bash
go get github.com/google/go-github/v82
go get github.com/google/go-github/v83
```

will resolve and add the package to the current development module, along with its dependencies.

Alternatively the same can be achieved if you use import in a package:

```go
import "github.com/google/go-github/v82/github"
import "github.com/google/go-github/v83/github"
```

and run `go get` without parameters.

Finally, to use the top-of-trunk version of this repo, use the following command:

```bash
go get github.com/google/go-github/v82@master
go get github.com/google/go-github/v83@master
```

To discover all the changes that have occurred since a prior release, you can
first clone the repo, then run (for example):

```bash
go run tools/gen-release-notes/main.go --tag v82.0.0
go run tools/gen-release-notes/main.go --tag v83.0.0
```

## Usage ##

```go
import "github.com/google/go-github/v82/github"
import "github.com/google/go-github/v83/github"
```

Construct a new GitHub client, then use the various services on the client to
Expand Down Expand Up @@ -108,7 +108,7 @@ include the specified OAuth token. Therefore, authenticated clients should
almost never be shared between different users.

For API methods that require HTTP Basic Authentication, use the
[`BasicAuthTransport`](https://pkg.go.dev/github.com/google/go-github/v82/github#BasicAuthTransport).
[`BasicAuthTransport`](https://pkg.go.dev/github.com/google/go-github/v83/github#BasicAuthTransport).

#### As a GitHub App ####

Expand All @@ -131,7 +131,7 @@ import (
"net/http"

"github.com/bradleyfalzon/ghinstallation/v2"
"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
)

func main() {
Expand Down Expand Up @@ -165,7 +165,7 @@ import (
"os"
"strconv"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
"github.com/jferrl/go-githubauth"
"golang.org/x/oauth2"
)
Expand Down Expand Up @@ -434,7 +434,7 @@ For complete usage of go-github, see the full [package docs][].

[GitHub API v3]: https://docs.github.com/en/rest
[personal access token]: https://github.com/blog/1509-personal-api-tokens
[package docs]: https://pkg.go.dev/github.com/google/go-github/v82/github
[package docs]: https://pkg.go.dev/github.com/google/go-github/v83/github
[GraphQL API v4]: https://developer.github.com/v4/
[shurcooL/githubv4]: https://github.com/shurcooL/githubv4
[GitHub webhook events]: https://docs.github.com/en/developers/webhooks-and-events/webhooks/webhook-events-and-payloads
Expand Down Expand Up @@ -508,7 +508,7 @@ Versions prior to 48.2.0 are not listed.

| go-github Version | GitHub v3 API Version |
| ----------------- | --------------------- |
| 82.0.0 | 2022-11-28 |
| 83.0.0 | 2022-11-28 |
| ... | 2022-11-28 |
| 48.2.0 | 2022-11-28 |

Expand Down
2 changes: 1 addition & 1 deletion example/actionpermissions/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"log"
"os"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
)

var (
Expand Down
2 changes: 1 addition & 1 deletion example/appengine/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"net/http"
"os"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
"google.golang.org/appengine"
"google.golang.org/appengine/log"
)
Expand Down
2 changes: 1 addition & 1 deletion example/basicauth/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"os"
"strings"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
"golang.org/x/term"
)

Expand Down
2 changes: 1 addition & 1 deletion example/codespaces/newreposecretwithxcrypto/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ import (
"log"
"os"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
"golang.org/x/crypto/nacl/box"
)

Expand Down
2 changes: 1 addition & 1 deletion example/codespaces/newusersecretwithxcrypto/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import (
"log"
"os"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
"golang.org/x/crypto/nacl/box"
)

Expand Down
6 changes: 3 additions & 3 deletions example/commitpr/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
//
// Note, if you want to push a single file, you probably prefer to use the
// content API. An example is available here:
// https://pkg.go.dev/github.com/google/go-github/v82/github#example-RepositoriesService-CreateFile
// https://pkg.go.dev/github.com/google/go-github/v83/github#example-RepositoriesService-CreateFile
//
// Note, for this to work at least 1 commit is needed, so you if you use this
// after creating a repository you might want to make sure you set `AutoInit` to
Expand All @@ -33,7 +33,7 @@ import (
"time"

"github.com/ProtonMail/go-crypto/openpgp"
"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
)

var (
Expand Down Expand Up @@ -178,7 +178,7 @@ func pushCommit(ref *github.Reference, tree *github.Tree) (err error) {
return err
}

// createPR creates a pull request. Based on: https://pkg.go.dev/github.com/google/go-github/v82/github#example-PullRequestsService-Create
// createPR creates a pull request. Based on: https://pkg.go.dev/github.com/google/go-github/v83/github#example-PullRequestsService-Create
func createPR() (err error) {
if *prSubject == "" {
return errors.New("missing `-pr-title` flag; skipping PR creation")
Expand Down
10 changes: 5 additions & 5 deletions example/go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/google/go-github/v82/example
module github.com/google/go-github/v83/example

go 1.24.0

Expand All @@ -7,8 +7,8 @@ require (
github.com/bradleyfalzon/ghinstallation/v2 v2.17.0
github.com/gofri/go-github-pagination v1.0.1
github.com/gofri/go-github-ratelimit/v2 v2.0.2
github.com/google/go-github/v82 v82.0.0
github.com/google/go-github/v82/otel v0.0.0-00010101000000-000000000000
github.com/google/go-github/v83 v83.0.0
github.com/google/go-github/v83/otel v0.0.0-00010101000000-000000000000
github.com/sigstore/sigstore-go v0.6.1
go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.40.0
go.opentelemetry.io/otel/sdk v1.40.0
Expand Down Expand Up @@ -105,6 +105,6 @@ require (
)

// Use version at HEAD, not the latest published.
replace github.com/google/go-github/v82 => ../
replace github.com/google/go-github/v83 => ../

replace github.com/google/go-github/v82/otel => ../otel
replace github.com/google/go-github/v83/otel => ../otel
2 changes: 1 addition & 1 deletion example/listenvironments/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"log"
"os"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
)

func main() {
Expand Down
2 changes: 1 addition & 1 deletion example/migrations/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"context"
"fmt"

"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
)

func fetchAllUserMigrations() ([]*github.UserMigration, error) {
Expand Down
2 changes: 1 addition & 1 deletion example/newfilewithappauth/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
"time"

"github.com/bradleyfalzon/ghinstallation/v2"
"github.com/google/go-github/v82/github"
"github.com/google/go-github/v83/github"
)

func main() {
Expand Down
Loading
Loading