8000 Add has_discussions field to repository by gronsy · Pull Request #2589 · google/go-github · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add has_discussions field to repository #2589

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree 8000 to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 4, 2022
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
8 changes: 8 additions & 0 deletions github/github-accessors.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions github/github-accessors_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion github/github-stringify_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 9 additions & 6 deletions github/repos.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ type Repository struct {
HasPages *bool `json:"has_pages,omitempty"`
HasProjects *bool `json:"has_projects,omitempty"`
HasDownloads *bool `json:"has_downloads,omitempty"`
HasDiscussions *bool `json:"has_discussions,omitempty"`
IsTemplate *bool `json:"is_template,omitempty"`
LicenseTemplate *string `json:"license_template,omitempty"`
GitignoreTemplate *string `json:"gitignore_template,omitempty"`
Expand Down Expand Up @@ -365,12 +366,13 @@ type createRepoRequest struct {
Description *string `json:"description,omitempty"`
Homepage *string `json:"homepage,omitempty"`

Private *bool `json:"private,omitempty"`
Visibility *string `json:"visibility,omitempty"`
HasIssues *bool `json:"has_issues,omitempty"`
HasProjects *bool `json:"has_projects,omitempty"`
HasWiki *bool `json:"has_wiki,omitempty"`
IsTemplate *bool `json:"is_template,omitempty"`
Private *bool `json:"private,omitempty"`
Visibility *string `json:"visibility,omitempty"`
HasIssues *bool `json:"has_issues,omitempty"`
HasProjects *bool `json:"has_projects,omitempty"`
HasWiki *bool `json:"has_wiki,omitempty"`
HasDiscussions *bool `json:"has_discussions,omitempty"`
IsTemplate *bool `json:"is_template,omitempty"`

// Creating an organization repository. Required for non-owners.
TeamID *int64 `json:"team_id,omitempty"`
Expand Down Expand Up @@ -423,6 +425,7 @@ func (s *RepositoriesService) Create(ctx context.Context, org string, repo *Repo
HasIssues: repo.HasIssues,
HasProjects: repo.HasProjects,
HasWiki: repo.HasWiki,
HasDiscussions: repo.HasDiscussions,
IsTemplate: repo.IsTemplate,
TeamID: repo.TeamID,
AutoInit: repo.AutoInit,
Expand Down
0