Update go-github and remove redirect
This commit is contained in:
parent
adaeaa48f8
commit
80452aac39
148 changed files with 748 additions and 80 deletions
4
go.mod
4
go.mod
|
|
@ -6,7 +6,7 @@ require (
|
|||
github.com/BurntSushi/toml v0.4.1
|
||||
github.com/go-resty/resty/v2 v2.7.0
|
||||
github.com/golang-jwt/jwt v3.2.2+incompatible
|
||||
github.com/google/go-github/v47 v47.1.0
|
||||
github.com/google/go-github/v48 v48.0.0
|
||||
github.com/google/uuid v1.3.0
|
||||
github.com/gorilla/handlers v1.5.1
|
||||
github.com/gorilla/mux v1.8.0
|
||||
|
|
@ -71,5 +71,3 @@ require (
|
|||
gopkg.in/macaroon-bakery.v2 v2.3.0 // indirect
|
||||
gopkg.in/macaroon.v2 v2.1.0 // indirect
|
||||
)
|
||||
|
||||
replace github.com/google/go-github/v47 => github.com/gabriel-samfira/go-github/v47 v47.1.1-0.20221013145953-21e3b4d7b0c1
|
||||
|
|
|
|||
4
go.sum
4
go.sum
|
|
@ -64,8 +64,6 @@ github.com/frankban/quicktest v1.7.2/go.mod h1:jaStnuzAqU1AJdCO0l53JDCJrVDKcS03D
|
|||
github.com/frankban/quicktest v1.10.0/go.mod h1:ui7WezCLWMWxVWr1GETZY3smRy0G4KWq9vcPtJmFl7Y=
|
||||
github.com/frankban/quicktest v1.11.3 h1:8sXhOn0uLys67V8EsXLc6eszDs8VXWxL3iRvebPhedY=
|
||||
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
|
||||
github.com/gabriel-samfira/go-github/v47 v47.1.1-0.20221013145953-21e3b4d7b0c1 h1:CNZ1asZM2ABO6DLFPS86CkGMEp5nFSQnpAECOOhYBGo=
|
||||
github.com/gabriel-samfira/go-github/v47 v47.1.1-0.20221013145953-21e3b4d7b0c1/go.mod h1:VPZBXNbFSJGjyjFRUKo9vZGawTajnWzC/YjGw/oFKi0=
|
||||
github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
|
||||
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
|
||||
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
|
||||
|
|
@ -119,6 +117,8 @@ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
|
|||
github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
|
||||
github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
|
||||
github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38=
|
||||
github.com/google/go-github/v48 v48.0.0 h1:9H5fWVXFK6ZsRriyPbjtnFAkJnoj0WKFtTYfpCRrTm8=
|
||||
github.com/google/go-github/v48 v48.0.0/go.mod h1:dDlehKBDo850ZPvCTK0sEqTCVWcrGl2LcDiajkYi89Y=
|
||||
github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8=
|
||||
github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU=
|
||||
github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ import (
|
|||
"garm/runner/providers/common"
|
||||
"time"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
uuid "github.com/satori/go.uuid"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ package mocks
|
|||
import (
|
||||
context "context"
|
||||
|
||||
github "github.com/google/go-github/v47/github"
|
||||
github "github.com/google/go-github/v48/github"
|
||||
mock "github.com/stretchr/testify/mock"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ package mocks
|
|||
import (
|
||||
context "context"
|
||||
|
||||
github "github.com/google/go-github/v47/github"
|
||||
github "github.com/google/go-github/v48/github"
|
||||
mock "github.com/stretchr/testify/mock"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package common
|
|||
import (
|
||||
"context"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
)
|
||||
|
||||
// GithubClient that describes the minimum list of functions we need to interact with github.
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import (
|
|||
"garm/runner/common"
|
||||
"garm/util"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ package pool
|
|||
import (
|
||||
"garm/params"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
)
|
||||
|
||||
type poolHelper interface {
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import (
|
|||
"garm/runner/common"
|
||||
"garm/util"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ import (
|
|||
"garm/runner/common"
|
||||
providerCommon "garm/runner/providers/common"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
"github.com/google/uuid"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import (
|
|||
"garm/runner/common"
|
||||
"garm/util"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ import (
|
|||
"garm/runner/common"
|
||||
"garm/util"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
lxd "github.com/lxc/lxd/client"
|
||||
"github.com/lxc/lxd/shared/api"
|
||||
"github.com/pkg/errors"
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ import (
|
|||
"garm/params"
|
||||
"garm/runner/common"
|
||||
|
||||
"github.com/google/go-github/v47/github"
|
||||
"github.com/google/go-github/v48/github"
|
||||
"github.com/pkg/errors"
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
"golang.org/x/oauth2"
|
||||
|
|
|
|||
46
vendor/github.com/google/go-github/v47/github/orgs_custom_roles.go
generated
vendored
46
vendor/github.com/google/go-github/v47/github/orgs_custom_roles.go
generated
vendored
|
|
@ -1,46 +0,0 @@
|
|||
// Copyright 2022 The go-github AUTHORS. All rights reserved.
|
||||
//
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package github
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// OrganizationCustomRepoRoles represents custom repository roles available in specified organization.
|
||||
type OrganizationCustomRepoRoles struct {
|
||||
TotalCount *int `json:"total_count,omitempty"`
|
||||
CustomRepoRoles []*CustomRepoRoles `json:"custom_roles,omitempty"`
|
||||
}
|
||||
|
||||
// CustomRepoRoles represents custom repository roles for an organization.
|
||||
// See https://docs.github.com/en/enterprise-cloud@latest/organizations/managing-peoples-access-to-your-organization-with-roles/managing-custom-repository-roles-for-an-organization
|
||||
// for more information.
|
||||
type CustomRepoRoles struct {
|
||||
ID *int64 `json:"id,omitempty"`
|
||||
Name *string `json:"name,omitempty"`
|
||||
}
|
||||
|
||||
// ListCustomRepoRoles lists the custom repository roles available in this organization.
|
||||
// In order to see custom repository roles in an organization, the authenticated user must be an organization owner.
|
||||
//
|
||||
// GitHub API docs: https://docs.github.com/en/rest/orgs/custom-roles#list-custom-repository-roles-in-an-organization
|
||||
func (s *OrganizationsService) ListCustomRepoRoles(ctx context.Context, org string) (*OrganizationCustomRepoRoles, *Response, error) {
|
||||
u := fmt.Sprintf("orgs/%v/custom_roles", org)
|
||||
|
||||
req, err := s.client.NewRequest("GET", u, nil)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
||||
customRepoRoles := new(OrganizationCustomRepoRoles)
|
||||
resp, err := s.client.Do(ctx, req, customRepoRoles)
|
||||
if err != nil {
|
||||
return nil, resp, err
|
||||
}
|
||||
|
||||
return customRepoRoles, resp, nil
|
||||
}
|
||||
|
|
@ -59,6 +59,7 @@ Beyang Liu <beyang.liu@gmail.com>
|
|||
Billy Keyes <bluekeyes@gmail.com>
|
||||
Billy Lynch <wlynch92@gmail.com>
|
||||
Björn Häuser <b.haeuser@rebuy.de>
|
||||
Bjorn Neergaard <bjorn@neersighted.com>
|
||||
boljen <bol.christophe@gmail.com>
|
||||
Brad Harris <bmharris@gmail.com>
|
||||
Brad Moylan <moylan.brad@gmail.com>
|
||||
|
|
@ -8,7 +8,7 @@ Package github provides a client for using the GitHub API.
|
|||
|
||||
Usage:
|
||||
|
||||
import "github.com/google/go-github/v47/github" // with go modules enabled (GO111MODULE=on or outside GOPATH)
|
||||
import "github.com/google/go-github/v48/github" // with go modules enabled (GO111MODULE=on or outside GOPATH)
|
||||
import "github.com/google/go-github/github" // with go modules disabled
|
||||
|
||||
Construct a new GitHub client, then use the various services on the client to
|
||||
|
|
@ -12,7 +12,7 @@ import (
|
|||
|
||||
// ListRunnerApplicationDownloads lists self-hosted runner application binaries that can be downloaded and run.
|
||||
//
|
||||
// GitHub API docs: https://docs.github.com/en/rest/actions/self-hosted-runners#list-runner-applications-for-a-repository
|
||||
// GitHub API docs: https://docs.github.com/en/rest/actions/self-hosted-runners#list-runner-applications-for-an-enterprise
|
||||
func (s *EnterpriseService) ListRunnerApplicationDownloads(ctx context.Context, enterprise string) ([]*RunnerApplicationDownload, *Response, error) {
|
||||
u := fmt.Sprintf("enterprises/%v/actions/runners/downloads", enterprise)
|
||||
req, err := s.client.NewRequest("GET", u, nil)
|
||||
|
|
@ -86,6 +86,14 @@ func (a *ActionsPermissionsRepository) GetSelectedActionsURL() string {
|
|||
return *a.SelectedActionsURL
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (a *AdminEnforcedChanges) GetFrom() bool {
|
||||
if a == nil || a.From == nil {
|
||||
return false
|
||||
}
|
||||
return *a.From
|
||||
}
|
||||
|
||||
// GetURL returns the URL field if it's non-nil, zero value otherwise.
|
||||
func (a *AdminEnforcement) GetURL() string {
|
||||
if a == nil || a.URL == nil {
|
||||
|
|
@ -414,6 +422,14 @@ func (a *Alert) GetURL() string {
|
|||
return *a.URL
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (a *AllowDeletionsEnforcementLevelChanges) GetFrom() string {
|
||||
if a == nil || a.From == nil {
|
||||
return ""
|
||||
}
|
||||
return *a.From
|
||||
}
|
||||
|
||||
// GetRef returns the Ref field if it's non-nil, zero value otherwise.
|
||||
func (a *AnalysesListOptions) GetRef() string {
|
||||
if a == nil || a.Ref == nil {
|
||||
|
|
@ -1366,6 +1382,14 @@ func (a *AuthorizedActorsOnly) GetFrom() bool {
|
|||
return *a.From
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (a *AuthorizedDismissalActorsOnlyChanges) GetFrom() bool {
|
||||
if a == nil || a.From == nil {
|
||||
return false
|
||||
}
|
||||
return *a.From
|
||||
}
|
||||
|
||||
// GetID returns the ID field if it's non-nil, zero value otherwise.
|
||||
func (a *Autolink) GetID() int64 {
|
||||
if a == nil || a.ID == nil {
|
||||
|
|
@ -3542,6 +3566,38 @@ func (c *CreateOrgInvitationOptions) GetRole() string {
|
|||
return *c.Role
|
||||
}
|
||||
|
||||
// GetBaseRole returns the BaseRole field if it's non-nil, zero value otherwise.
|
||||
func (c *CreateOrUpdateCustomRoleOptions) GetBaseRole() string {
|
||||
if c == nil || c.BaseRole == nil {
|
||||
return ""
|
||||
}
|
||||
return *c.BaseRole
|
||||
}
|
||||
|
||||
// GetDescription returns the Description field if it's non-nil, zero value otherwise.
|
||||
func (c *CreateOrUpdateCustomRoleOptions) GetDescription() string {
|
||||
if c == nil || c.Description == nil {
|
||||
return ""
|
||||
}
|
||||
return *c.Description
|
||||
}
|
||||
|
||||
// GetName returns the Name field if it's non-nil, zero value otherwise.
|
||||
func (c *CreateOrUpdateCustomRoleOptions) GetName() string {
|
||||
if c == nil || c.Name == nil {
|
||||
return ""
|
||||
}
|
||||
return *c.Name
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (c *CreateProtectedChanges) GetFrom() bool {
|
||||
if c == nil || c.From == nil {
|
||||
return false
|
||||
}
|
||||
return *c.From
|
||||
}
|
||||
|
||||
// GetAllowsPublicRepositories returns the AllowsPublicRepositories field if it's non-nil, zero value otherwise.
|
||||
func (c *CreateRunnerGroupRequest) GetAllowsPublicRepositories() bool {
|
||||
if c == nil || c.AllowsPublicRepositories == nil {
|
||||
|
|
@ -3590,6 +3646,22 @@ func (c *CreateUserProjectOptions) GetBody() string {
|
|||
return *c.Body
|
||||
}
|
||||
|
||||
// GetBaseRole returns the BaseRole field if it's non-nil, zero value otherwise.
|
||||
func (c *CustomRepoRoles) GetBaseRole() string {
|
||||
if c == nil || c.BaseRole == nil {
|
||||
return ""
|
||||
}
|
||||
return *c.BaseRole
|
||||
}
|
||||
|
||||
// GetDescription returns the Description field if it's non-nil, zero value otherwise.
|
||||
func (c *CustomRepoRoles) GetDescription() string {
|
||||
if c == nil || c.Description == nil {
|
||||
return ""
|
||||
}
|
||||
return *c.Description
|
||||
}
|
||||
|
||||
// GetID returns the ID field if it's non-nil, zero value otherwise.
|
||||
func (c *CustomRepoRoles) GetID() int64 {
|
||||
if c == nil || c.ID == nil {
|
||||
|
|
@ -4534,6 +4606,14 @@ func (d *DismissedReview) GetState() string {
|
|||
return *d.State
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (d *DismissStaleReviewsOnPushChanges) GetFrom() bool {
|
||||
if d == nil || d.From == nil {
|
||||
return false
|
||||
}
|
||||
return *d.From
|
||||
}
|
||||
|
||||
// GetClientPayload returns the ClientPayload field if it's non-nil, zero value otherwise.
|
||||
func (d *DispatchRequestOptions) GetClientPayload() json.RawMessage {
|
||||
if d == nil || d.ClientPayload == nil {
|
||||
|
|
@ -8174,6 +8254,14 @@ func (l *License) GetURL() string {
|
|||
return *l.URL
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (l *LinearHistoryRequirementEnforcementLevelChanges) GetFrom() string {
|
||||
if l == nil || l.From == nil {
|
||||
return ""
|
||||
}
|
||||
return *l.From
|
||||
}
|
||||
|
||||
// GetAppID returns the AppID field if it's non-nil, zero value otherwise.
|
||||
func (l *ListCheckRunsOptions) GetAppID() int64 {
|
||||
if l == nil || l.AppID == nil {
|
||||
|
|
@ -11806,6 +11894,22 @@ func (p *Protection) GetRestrictions() *BranchRestrictions {
|
|||
return p.Restrictions
|
||||
}
|
||||
|
||||
// GetAdminEnforced returns the AdminEnforced field.
|
||||
func (p *ProtectionChanges) GetAdminEnforced() *AdminEnforcedChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.AdminEnforced
|
||||
}
|
||||
|
||||
// GetAllowDeletionsEnforcementLevel returns the AllowDeletionsEnforcementLevel field.
|
||||
func (p *ProtectionChanges) GetAllowDeletionsEnforcementLevel() *AllowDeletionsEnforcementLevelChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.AllowDeletionsEnforcementLevel
|
||||
}
|
||||
|
||||
// GetAuthorizedActorNames returns the AuthorizedActorNames field.
|
||||
func (p *ProtectionChanges) GetAuthorizedActorNames() *AuthorizedActorNames {
|
||||
if p == nil {
|
||||
|
|
@ -11822,6 +11926,94 @@ func (p *ProtectionChanges) GetAuthorizedActorsOnly() *AuthorizedActorsOnly {
|
|||
return p.AuthorizedActorsOnly
|
||||
}
|
||||
|
||||
// GetAuthorizedDismissalActorsOnly returns the AuthorizedDismissalActorsOnly field.
|
||||
func (p *ProtectionChanges) GetAuthorizedDismissalActorsOnly() *AuthorizedDismissalActorsOnlyChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.AuthorizedDismissalActorsOnly
|
||||
}
|
||||
|
||||
// GetCreateProtected returns the CreateProtected field.
|
||||
func (p *ProtectionChanges) GetCreateProtected() *CreateProtectedChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.CreateProtected
|
||||
}
|
||||
|
||||
// GetDismissStaleReviewsOnPush returns the DismissStaleReviewsOnPush field.
|
||||
func (p *ProtectionChanges) GetDismissStaleReviewsOnPush() *DismissStaleReviewsOnPushChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.DismissStaleReviewsOnPush
|
||||
}
|
||||
|
||||
// GetLinearHistoryRequirementEnforcementLevel returns the LinearHistoryRequirementEnforcementLevel field.
|
||||
func (p *ProtectionChanges) GetLinearHistoryRequirementEnforcementLevel() *LinearHistoryRequirementEnforcementLevelChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.LinearHistoryRequirementEnforcementLevel
|
||||
}
|
||||
|
||||
// GetPullRequestReviewsEnforcementLevel returns the PullRequestReviewsEnforcementLevel field.
|
||||
func (p *ProtectionChanges) GetPullRequestReviewsEnforcementLevel() *PullRequestReviewsEnforcementLevelChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.PullRequestReviewsEnforcementLevel
|
||||
}
|
||||
|
||||
// GetRequireCodeOwnerReview returns the RequireCodeOwnerReview field.
|
||||
func (p *ProtectionChanges) GetRequireCodeOwnerReview() *RequireCodeOwnerReviewChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.RequireCodeOwnerReview
|
||||
}
|
||||
|
||||
// GetRequiredConversationResolutionLevel returns the RequiredConversationResolutionLevel field.
|
||||
func (p *ProtectionChanges) GetRequiredConversationResolutionLevel() *RequiredConversationResolutionLevelChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.RequiredConversationResolutionLevel
|
||||
}
|
||||
|
||||
// GetRequiredDeploymentsEnforcementLevel returns the RequiredDeploymentsEnforcementLevel field.
|
||||
func (p *ProtectionChanges) GetRequiredDeploymentsEnforcementLevel() *RequiredDeploymentsEnforcementLevelChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.RequiredDeploymentsEnforcementLevel
|
||||
}
|
||||
|
||||
// GetRequiredStatusChecks returns the RequiredStatusChecks field.
|
||||
func (p *ProtectionChanges) GetRequiredStatusChecks() *RequiredStatusChecksChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.RequiredStatusChecks
|
||||
}
|
||||
|
||||
// GetRequiredStatusChecksEnforcementLevel returns the RequiredStatusChecksEnforcementLevel field.
|
||||
func (p *ProtectionChanges) GetRequiredStatusChecksEnforcementLevel() *RequiredStatusChecksEnforcementLevelChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.RequiredStatusChecksEnforcementLevel
|
||||
}
|
||||
|
||||
// GetSignatureRequirementEnforcementLevel returns the SignatureRequirementEnforcementLevel field.
|
||||
func (p *ProtectionChanges) GetSignatureRequirementEnforcementLevel() *SignatureRequirementEnforcementLevelChanges {
|
||||
if p == nil {
|
||||
return nil
|
||||
}
|
||||
return p.SignatureRequirementEnforcementLevel
|
||||
}
|
||||
|
||||
// GetAllowDeletions returns the AllowDeletions field if it's non-nil, zero value otherwise.
|
||||
func (p *ProtectionRequest) GetAllowDeletions() bool {
|
||||
if p == nil || p.AllowDeletions == nil {
|
||||
|
|
@ -13014,6 +13206,14 @@ func (p *PullRequestReviewsEnforcement) GetDismissalRestrictions() *DismissalRes
|
|||
return p.DismissalRestrictions
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (p *PullRequestReviewsEnforcementLevelChanges) GetFrom() string {
|
||||
if p == nil || p.From == nil {
|
||||
return ""
|
||||
}
|
||||
return *p.From
|
||||
}
|
||||
|
||||
// GetBypassPullRequestAllowancesRequest returns the BypassPullRequestAllowancesRequest field.
|
||||
func (p *PullRequestReviewsEnforcementRequest) GetBypassPullRequestAllowancesRequest() *BypassPullRequestAllowancesRequest {
|
||||
if p == nil {
|
||||
|
|
@ -16134,6 +16334,30 @@ func (r *RepoStatus) GetURL() string {
|
|||
return *r.URL
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (r *RequireCodeOwnerReviewChanges) GetFrom() bool {
|
||||
if r == nil || r.From == nil {
|
||||
return false
|
||||
}
|
||||
return *r.From
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (r *RequiredConversationResolutionLevelChanges) GetFrom() string {
|
||||
if r == nil || r.From == nil {
|
||||
return ""
|
||||
}
|
||||
return *r.From
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (r *RequiredDeploymentsEnforcementLevelChanges) GetFrom() string {
|
||||
if r == nil || r.From == nil {
|
||||
return ""
|
||||
}
|
||||
return *r.From
|
||||
}
|
||||
|
||||
// GetType returns the Type field if it's non-nil, zero value otherwise.
|
||||
func (r *RequiredReviewer) GetType() string {
|
||||
if r == nil || r.Type == nil {
|
||||
|
|
@ -16150,6 +16374,14 @@ func (r *RequiredStatusCheck) GetAppID() int64 {
|
|||
return *r.AppID
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (r *RequiredStatusChecksEnforcementLevelChanges) GetFrom() string {
|
||||
if r == nil || r.From == nil {
|
||||
return ""
|
||||
}
|
||||
return *r.From
|
||||
}
|
||||
|
||||
// GetStrict returns the Strict field if it's non-nil, zero value otherwise.
|
||||
func (r *RequiredStatusChecksRequest) GetStrict() bool {
|
||||
if r == nil || r.Strict == nil {
|
||||
|
|
@ -16582,6 +16814,62 @@ func (s *ScanningAnalysis) GetWarning() string {
|
|||
return *s.Warning
|
||||
}
|
||||
|
||||
// GetCreated returns the Created field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMMeta) GetCreated() Timestamp {
|
||||
if s == nil || s.Created == nil {
|
||||
return Timestamp{}
|
||||
}
|
||||
return *s.Created
|
||||
}
|
||||
|
||||
// GetLastModified returns the LastModified field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMMeta) GetLastModified() Timestamp {
|
||||
if s == nil || s.LastModified == nil {
|
||||
return Timestamp{}
|
||||
}
|
||||
return *s.LastModified
|
||||
}
|
||||
|
||||
// GetLocation returns the Location field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMMeta) GetLocation() string {
|
||||
if s == nil || s.Location == nil {
|
||||
return ""
|
||||
}
|
||||
return *s.Location
|
||||
}
|
||||
|
||||
// GetResourceType returns the ResourceType field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMMeta) GetResourceType() string {
|
||||
if s == nil || s.ResourceType == nil {
|
||||
return ""
|
||||
}
|
||||
return *s.ResourceType
|
||||
}
|
||||
|
||||
// GetItemsPerPage returns the ItemsPerPage field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMProvisionedIdentities) GetItemsPerPage() int {
|
||||
if s == nil || s.ItemsPerPage == nil {
|
||||
return 0
|
||||
}
|
||||
return *s.ItemsPerPage
|
||||
}
|
||||
|
||||
// GetStartIndex returns the StartIndex field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMProvisionedIdentities) GetStartIndex() int {
|
||||
if s == nil || s.StartIndex == nil {
|
||||
return 0
|
||||
}
|
||||
return *s.StartIndex
|
||||
}
|
||||
|
||||
// GetTotalResults returns the TotalResults field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMProvisionedIdentities) GetTotalResults() int {
|
||||
if s == nil || s.TotalResults == nil {
|
||||
return 0
|
||||
}
|
||||
return *s.TotalResults
|
||||
}
|
||||
|
||||
// GetActive returns the Active field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMUserAttributes) GetActive() bool {
|
||||
if s == nil || s.Active == nil {
|
||||
|
|
@ -16606,6 +16894,22 @@ func (s *SCIMUserAttributes) GetExternalID() string {
|
|||
return *s.ExternalID
|
||||
}
|
||||
|
||||
// GetID returns the ID field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMUserAttributes) GetID() string {
|
||||
if s == nil || s.ID == nil {
|
||||
return ""
|
||||
}
|
||||
return *s.ID
|
||||
}
|
||||
|
||||
// GetMeta returns the Meta field.
|
||||
func (s *SCIMUserAttributes) GetMeta() *SCIMMeta {
|
||||
if s == nil {
|
||||
return nil
|
||||
}
|
||||
return s.Meta
|
||||
}
|
||||
|
||||
// GetPrimary returns the Primary field if it's non-nil, zero value otherwise.
|
||||
func (s *SCIMUserEmail) GetPrimary() bool {
|
||||
if s == nil || s.Primary == nil {
|
||||
|
|
@ -16894,6 +17198,14 @@ func (s *SecretScanningAlertUpdateOptions) GetState() string {
|
|||
return *s.State
|
||||
}
|
||||
|
||||
// GetStatus returns the Status field if it's non-nil, zero value otherwise.
|
||||
func (s *SecretScanningPushProtection) GetStatus() string {
|
||||
if s == nil || s.Status == nil {
|
||||
return ""
|
||||
}
|
||||
return *s.Status
|
||||
}
|
||||
|
||||
// GetDescription returns the Description field if it's non-nil, zero value otherwise.
|
||||
func (s *SecurityAdvisory) GetDescription() string {
|
||||
if s == nil || s.Description == nil {
|
||||
|
|
@ -16982,6 +17294,14 @@ func (s *SecurityAndAnalysis) GetSecretScanning() *SecretScanning {
|
|||
return s.SecretScanning
|
||||
}
|
||||
|
||||
// GetSecretScanningPushProtection returns the SecretScanningPushProtection field.
|
||||
func (s *SecurityAndAnalysis) GetSecretScanningPushProtection() *SecretScanningPushProtection {
|
||||
if s == nil {
|
||||
return nil
|
||||
}
|
||||
return s.SecretScanningPushProtection
|
||||
}
|
||||
|
||||
// GetTotalCount returns the TotalCount field if it's non-nil, zero value otherwise.
|
||||
func (s *SelectedReposList) GetTotalCount() int {
|
||||
if s == nil || s.TotalCount == nil {
|
||||
|
|
@ -16998,6 +17318,14 @@ func (s *ServiceHook) GetName() string {
|
|||
return *s.Name
|
||||
}
|
||||
|
||||
// GetFrom returns the From field if it's non-nil, zero value otherwise.
|
||||
func (s *SignatureRequirementEnforcementLevelChanges) GetFrom() string {
|
||||
if s == nil || s.From == nil {
|
||||
return ""
|
||||
}
|
||||
return *s.From
|
||||
}
|
||||
|
||||
// GetEnabled returns the Enabled field if it's non-nil, zero value otherwise.
|
||||
func (s *SignaturesProtectedBranch) GetEnabled() bool {
|
||||
if s == nil || s.Enabled == nil {
|
||||
|
|
@ -17142,6 +17470,38 @@ func (s *SourceImportAuthor) GetURL() string {
|
|||
return *s.URL
|
||||
}
|
||||
|
||||
// GetCreatedAt returns the CreatedAt field if it's non-nil, zero value otherwise.
|
||||
func (s *SSHSigningKey) GetCreatedAt() Timestamp {
|
||||
if s == nil || s.CreatedAt == nil {
|
||||
return Timestamp{}
|
||||
}
|
||||
return *s.CreatedAt
|
||||
}
|
||||
|
||||
// GetID returns the ID field if it's non-nil, zero value otherwise.
|
||||
func (s *SSHSigningKey) GetID() int64 {
|
||||
if s == nil || s.ID == nil {
|
||||
return 0
|
||||
}
|
||||
return *s.ID
|
||||
}
|
||||
|
||||
// GetKey returns the Key field if it's non-nil, zero value otherwise.
|
||||
func (s *SSHSigningKey) GetKey() string {
|
||||
if s == nil || s.Key == nil {
|
||||
return ""
|
||||
}
|
||||
return *s.Key
|
||||
}
|
||||
|
||||
// GetTitle returns the Title field if it's non-nil, zero value otherwise.
|
||||
func (s *SSHSigningKey) GetTitle() string {
|
||||
if s == nil || s.Title == nil {
|
||||
return ""
|
||||
}
|
||||
return *s.Title
|
||||
}
|
||||
|
||||
// GetAction returns the Action field if it's non-nil, zero value otherwise.
|
||||
func (s *StarEvent) GetAction() string {
|
||||
if s == nil || s.Action == nil {
|
||||
|
|
@ -28,7 +28,7 @@ import (
|
|||
)
|
||||
|
||||
const (
|
||||
Version = "v47.0.0"
|
||||
Version = "v48.0.0"
|
||||
|
||||
defaultBaseURL = "https://api.github.com/"
|
||||
defaultUserAgent = "go-github" + "/" + Version
|
||||
120
vendor/github.com/google/go-github/v48/github/orgs_custom_roles.go
generated
vendored
Normal file
120
vendor/github.com/google/go-github/v48/github/orgs_custom_roles.go
generated
vendored
Normal file
|
|
@ -0,0 +1,120 @@
|
|||
// Copyright 2022 The go-github AUTHORS. All rights reserved.
|
||||
//
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package github
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// OrganizationCustomRepoRoles represents custom repository roles available in specified organization.
|
||||
type OrganizationCustomRepoRoles struct {
|
||||
TotalCount *int `json:"total_count,omitempty"`
|
||||
CustomRepoRoles []*CustomRepoRoles `json:"custom_roles,omitempty"`
|
||||
}
|
||||
|
||||
// CustomRepoRoles represents custom repository roles for an organization.
|
||||
// See https://docs.github.com/en/enterprise-cloud@latest/organizations/managing-peoples-access-to-your-organization-with-roles/managing-custom-repository-roles-for-an-organization
|
||||
// for more information.
|
||||
type CustomRepoRoles struct {
|
||||
ID *int64 `json:"id,omitempty"`
|
||||
Name *string `json:"name,omitempty"`
|
||||
Description *string `json:"description,omitempty"`
|
||||
BaseRole *string `json:"base_role,omitempty"`
|
||||
Permissions []string `json:"permissions,omitempty"`
|
||||
}
|
||||
|
||||
// ListCustomRepoRoles lists the custom repository roles available in this organization.
|
||||
// In order to see custom repository roles in an organization, the authenticated user must be an organization owner.
|
||||
//
|
||||
// GitHub API docs: https://docs.github.com/en/rest/orgs/custom-roles#list-custom-repository-roles-in-an-organization
|
||||
func (s *OrganizationsService) ListCustomRepoRoles(ctx context.Context, org string) (*OrganizationCustomRepoRoles, *Response, error) {
|
||||
u := fmt.Sprintf("orgs/%v/custom_roles", org)
|
||||
|
||||
req, err := s.client.NewRequest("GET", u, nil)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
||||
customRepoRoles := new(OrganizationCustomRepoRoles)
|
||||
resp, err := s.client.Do(ctx, req, customRepoRoles)
|
||||
if err != nil {
|
||||
return nil, resp, err
|
||||
}
|
||||
|
||||
return customRepoRoles, resp, nil
|
||||
}
|
||||
|
||||
// CreateOrUpdateCustomRoleOptions represents options required to create or update a custom repository role.
|
||||
type CreateOrUpdateCustomRoleOptions struct {
|
||||
Name *string `json:"name,omitempty"`
|
||||
Description *string `json:"description,omitempty"`
|
||||
BaseRole *string `json:"base_role,omitempty"`
|
||||
Permissions []string `json:"permissions,omitempty"`
|
||||
}
|
||||
|
||||
// CreateCustomRepoRole creates a custom repository role in this organization.
|
||||
// In order to create custom repository roles in an organization, the authenticated user must be an organization owner.
|
||||
//
|
||||
// GitHub API docs: https://docs.github.com/en/rest/orgs/custom-roles#create-a-custom-role
|
||||
func (s *OrganizationsService) CreateCustomRepoRole(ctx context.Context, org string, opts *CreateOrUpdateCustomRoleOptions) (*CustomRepoRoles, *Response, error) {
|
||||
u := fmt.Sprintf("orgs/%v/custom_roles", org)
|
||||
|
||||
req, err := s.client.NewRequest("POST", u, opts)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
||||
resultingRole := new(CustomRepoRoles)
|
||||
resp, err := s.client.Do(ctx, req, resultingRole)
|
||||
if err != nil {
|
||||
return nil, resp, err
|
||||
}
|
||||
|
||||
return resultingRole, resp, err
|
||||
}
|
||||
|
||||
// UpdateCustomRepoRole updates a custom repository role in this organization.
|
||||
// In order to update custom repository roles in an organization, the authenticated user must be an organization owner.
|
||||
//
|
||||
// GitHub API docs: https://docs.github.com/en/rest/orgs/custom-roles#update-a-custom-role
|
||||
func (s *OrganizationsService) UpdateCustomRepoRole(ctx context.Context, org, roleID string, opts *CreateOrUpdateCustomRoleOptions) (*CustomRepoRoles, *Response, error) {
|
||||
u := fmt.Sprintf("orgs/%v/custom_roles/%v", org, roleID)
|
||||
|
||||
req, err := s.client.NewRequest("PATCH", u, opts)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
||||
resultingRole := new(CustomRepoRoles)
|
||||
resp, err := s.client.Do(ctx, req, resultingRole)
|
||||
if err != nil {
|
||||
return nil, resp, err
|
||||
}
|
||||
|
||||
return resultingRole, resp, err
|
||||
}
|
||||
|
||||
// DeleteCustomRepoRole deletes an existing custom repository role in this organization.
|
||||
// In order to delete custom repository roles in an organization, the authenticated user must be an organization owner.
|
||||
//
|
||||
// GitHub API docs: https://docs.github.com/en/rest/orgs/custom-roles#delete-a-custom-role
|
||||
func (s *OrganizationsService) DeleteCustomRepoRole(ctx context.Context, org, roleID string) (*Response, error) {
|
||||
u := fmt.Sprintf("orgs/%v/custom_roles/%v", org, roleID)
|
||||
|
||||
req, err := s.client.NewRequest("DELETE", u, nil)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
resultingRole := new(CustomRepoRoles)
|
||||
resp, err := s.client.Do(ctx, req, resultingRole)
|
||||
if err != nil {
|
||||
return resp, err
|
||||
}
|
||||
|
||||
return resp, nil
|
||||
}
|
||||
|
|
@ -205,8 +205,9 @@ type RepositoryListOptions struct {
|
|||
// SecurityAndAnalysis specifies the optional advanced security features
|
||||
// that are enabled on a given repository.
|
||||
type SecurityAndAnalysis struct {
|
||||
AdvancedSecurity *AdvancedSecurity `json:"advanced_security,omitempty"`
|
||||
SecretScanning *SecretScanning `json:"secret_scanning,omitempty"`
|
||||
AdvancedSecurity *AdvancedSecurity `json:"advanced_security,omitempty"`
|
||||
SecretScanning *SecretScanning `json:"secret_scanning,omitempty"`
|
||||
SecretScanningPushProtection *SecretScanningPushProtection `json:"secret_scanning_push_protection,omitempty"`
|
||||
}
|
||||
|
||||
func (s SecurityAndAnalysis) String() string {
|
||||
|
|
@ -235,6 +236,13 @@ func (s SecretScanning) String() string {
|
|||
return Stringify(s)
|
||||
}
|
||||
|
||||
// SecretScanningPushProtection specifies the state of secret scanning push protection on a repository.
|
||||
//
|
||||
// GitHub API docs: https://docs.github.com/en/code-security/secret-scanning/about-secret-scanning#about-secret-scanning-for-partner-patterns
|
||||
type SecretScanningPushProtection struct {
|
||||
Status *string `json:"status,omitempty"`
|
||||
}
|
||||
|
||||
// List the repositories for a user. Passing the empty string will list
|
||||
// repositories for the authenticated user.
|
||||
//
|
||||
|
|
@ -864,8 +872,31 @@ type BranchProtectionRule struct {
|
|||
|
||||
// ProtectionChanges represents the changes to the rule if the BranchProtection was edited.
|
||||
type ProtectionChanges struct {
|
||||
AuthorizedActorsOnly *AuthorizedActorsOnly `json:"authorized_actors_only,omitempty"`
|
||||
AuthorizedActorNames *AuthorizedActorNames `json:"authorized_actor_names,omitempty"`
|
||||
AdminEnforced *AdminEnforcedChanges `json:"admin_enforced,omitempty"`
|
||||
AllowDeletionsEnforcementLevel *AllowDeletionsEnforcementLevelChanges `json:"allow_deletions_enforcement_level,omitempty"`
|
||||
AuthorizedActorNames *AuthorizedActorNames `json:"authorized_actor_names,omitempty"`
|
||||
AuthorizedActorsOnly *AuthorizedActorsOnly `json:"authorized_actors_only,omitempty"`
|
||||
AuthorizedDismissalActorsOnly *AuthorizedDismissalActorsOnlyChanges `json:"authorized_dismissal_actors_only,omitempty"`
|
||||
CreateProtected *CreateProtectedChanges `json:"create_protected,omitempty"`
|
||||
DismissStaleReviewsOnPush *DismissStaleReviewsOnPushChanges `json:"dismiss_stale_reviews_on_push,omitempty"`
|
||||
LinearHistoryRequirementEnforcementLevel *LinearHistoryRequirementEnforcementLevelChanges `json:"linear_history_requirement_enforcement_level,omitempty"`
|
||||
PullRequestReviewsEnforcementLevel *PullRequestReviewsEnforcementLevelChanges `json:"pull_request_reviews_enforcement_level,omitempty"`
|
||||
RequireCodeOwnerReview *RequireCodeOwnerReviewChanges `json:"require_code_owner_review,omitempty"`
|
||||
RequiredConversationResolutionLevel *RequiredConversationResolutionLevelChanges `json:"required_conversation_resolution_level,omitempty"`
|
||||
RequiredDeploymentsEnforcementLevel *RequiredDeploymentsEnforcementLevelChanges `json:"required_deployments_enforcement_level,omitempty"`
|
||||
RequiredStatusChecks *RequiredStatusChecksChanges `json:"required_status_checks,omitempty"`
|
||||
RequiredStatusChecksEnforcementLevel *RequiredStatusChecksEnforcementLevelChanges `json:"required_status_checks_enforcement_level,omitempty"`
|
||||
SignatureRequirementEnforcementLevel *SignatureRequirementEnforcementLevelChanges `json:"signature_requirement_enforcement_level,omitempty"`
|
||||
}
|
||||
|
||||
// AdminEnforcedChanges represents the changes made to the AdminEnforced policy.
|
||||
type AdminEnforcedChanges struct {
|
||||
From *bool `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// AllowDeletionsEnforcementLevelChanges represents the changes made to the AllowDeletionsEnforcementLevel policy.
|
||||
type AllowDeletionsEnforcementLevelChanges struct {
|
||||
From *string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// AuthorizedActorNames represents who are authorized to edit the branch protection rules.
|
||||
|
|
@ -873,11 +904,66 @@ type AuthorizedActorNames struct {
|
|||
From []string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// AuthorizedActorsOnly represents if the branche rule can be edited by authorized actors only.
|
||||
// AuthorizedActorsOnly represents if the branch rule can be edited by authorized actors only.
|
||||
type AuthorizedActorsOnly struct {
|
||||
From *bool `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// AuthorizedDismissalActorsOnlyChanges represents the changes made to the AuthorizedDismissalActorsOnly policy.
|
||||
type AuthorizedDismissalActorsOnlyChanges struct {
|
||||
From *bool `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// CreateProtectedChanges represents the changes made to the CreateProtected policy.
|
||||
type CreateProtectedChanges struct {
|
||||
From *bool `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// DismissStaleReviewsOnPushChanges represents the changes made to the DismissStaleReviewsOnPushChanges policy.
|
||||
type DismissStaleReviewsOnPushChanges struct {
|
||||
From *bool `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// LinearHistoryRequirementEnforcementLevelChanges represents the changes made to the LinearHistoryRequirementEnforcementLevel policy.
|
||||
type LinearHistoryRequirementEnforcementLevelChanges struct {
|
||||
From *string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// PullRequestReviewsEnforcementLevelChanges represents the changes made to the PullRequestReviewsEnforcementLevel policy.
|
||||
type PullRequestReviewsEnforcementLevelChanges struct {
|
||||
From *string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// RequireCodeOwnerReviewChanges represents the changes made to the RequireCodeOwnerReview policy.
|
||||
type RequireCodeOwnerReviewChanges struct {
|
||||
From *bool `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// RequiredConversationResolutionLevelChanges represents the changes made to the RequiredConversationResolutionLevel policy.
|
||||
type RequiredConversationResolutionLevelChanges struct {
|
||||
From *string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// RequiredDeploymentsEnforcementLevelChanges represents the changes made to the RequiredDeploymentsEnforcementLevel policy.
|
||||
type RequiredDeploymentsEnforcementLevelChanges struct {
|
||||
From *string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// RequiredStatusChecksChanges represents the changes made to the RequiredStatusChecks policy.
|
||||
type RequiredStatusChecksChanges struct {
|
||||
From []string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// RequiredStatusChecksEnforcementLevelChanges represents the changes made to the RequiredStatusChecksEnforcementLevel policy.
|
||||
type RequiredStatusChecksEnforcementLevelChanges struct {
|
||||
From *string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// SignatureRequirementEnforcementLevelChanges represents the changes made to the SignatureRequirementEnforcementLevel policy.
|
||||
type SignatureRequirementEnforcementLevelChanges struct {
|
||||
From *string `json:"from,omitempty"`
|
||||
}
|
||||
|
||||
// ProtectionRequest represents a request to create/edit a branch's protection.
|
||||
type ProtectionRequest struct {
|
||||
RequiredStatusChecks *RequiredStatusChecks `json:"required_status_checks"`
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue