Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
go-gitlab
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
go-gitlab
Commits
33d299cf
Commit
33d299cf
authored
Oct 30, 2018
by
BernhardBerbuir
Committed by
Sander van Harmelen
Oct 30, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ProjectPushRule: mark optional attributes as omitempty (#508)
parent
d37154de
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
16 deletions
+16
-16
projects.go
projects.go
+16
-16
No files found.
projects.go
View file @
33d299cf
...
...
@@ -1076,14 +1076,14 @@ func (s *ProjectsService) GetProjectPushRules(pid interface{}, options ...Option
// GitLab API docs:
// https://docs.gitlab.com/ee/api/projects.html#add-project-push-rule
type
AddProjectPushRuleOptions
struct
{
DenyDeleteTag
*
bool
`url:"deny_delete_tag,omitempty" json:"deny_delete_tag"`
MemberCheck
*
bool
`url:"member_check,omitempty" json:"member_check"`
PreventSecrets
*
bool
`url:"prevent_secrets,omitempty" json:"prevent_secrets"`
CommitMessageRegex
*
string
`url:"commit_message_regex,omitempty" json:"commit_message_regex"`
BranchNameRegex
*
string
`url:"branch_name_regex,omitempty" json:"branch_name_regex"`
AuthorEmailRegex
*
string
`url:"author_email_regex,omitempty" json:"author_email_regex"`
FileNameRegex
*
string
`url:"file_name_regex,omitempty" json:"file_name_regex"`
MaxFileSize
*
int
`url:"max_file_size,omitempty" json:"max_file_size"`
DenyDeleteTag
*
bool
`url:"deny_delete_tag,omitempty" json:"deny_delete_tag
,omitempty
"`
MemberCheck
*
bool
`url:"member_check,omitempty" json:"member_check
,omitempty
"`
PreventSecrets
*
bool
`url:"prevent_secrets,omitempty" json:"prevent_secrets
,omitempty
"`
CommitMessageRegex
*
string
`url:"commit_message_regex,omitempty" json:"commit_message_regex
,omitempty
"`
BranchNameRegex
*
string
`url:"branch_name_regex,omitempty" json:"branch_name_regex
,omitempty
"`
AuthorEmailRegex
*
string
`url:"author_email_regex,omitempty" json:"author_email_regex
,omitempty
"`
FileNameRegex
*
string
`url:"file_name_regex,omitempty" json:"file_name_regex
,omitempty
"`
MaxFileSize
*
int
`url:"max_file_size,omitempty" json:"max_file_size
,omitempty
"`
}
// AddProjectPushRule adds a push rule to a specified project.
...
...
@@ -1117,14 +1117,14 @@ func (s *ProjectsService) AddProjectPushRule(pid interface{}, opt *AddProjectPus
// GitLab API docs:
// https://docs.gitlab.com/ee/api/projects.html#edit-project-push-rule
type
EditProjectPushRuleOptions
struct
{
AuthorEmailRegex
*
string
`url:"author_email_regex,omitempty" json:"author_email_regex"`
BranchNameRegex
*
string
`url:"branch_name_regex,omitempty" json:"branch_name_regex"`
CommitMessageRegex
*
string
`url:"commit_message_regex,omitempty" json:"commit_message_regex"`
FileNameRegex
*
string
`url:"file_name_regex,omitempty" json:"file_name_regex"`
DenyDeleteTag
*
bool
`url:"deny_delete_tag,omitempty" json:"deny_delete_tag"`
MemberCheck
*
bool
`url:"member_check,omitempty" json:"member_check"`
PreventSecrets
*
bool
`url:"prevent_secrets,omitempty" json:"prevent_secrets"`
MaxFileSize
*
int
`url:"max_file_size,omitempty" json:"max_file_size"`
AuthorEmailRegex
*
string
`url:"author_email_regex,omitempty" json:"author_email_regex
,omitempty
"`
BranchNameRegex
*
string
`url:"branch_name_regex,omitempty" json:"branch_name_regex
,omitempty
"`
CommitMessageRegex
*
string
`url:"commit_message_regex,omitempty" json:"commit_message_regex
,omitempty
"`
FileNameRegex
*
string
`url:"file_name_regex,omitempty" json:"file_name_regex
,omitempty
"`
DenyDeleteTag
*
bool
`url:"deny_delete_tag,omitempty" json:"deny_delete_tag
,omitempty
"`
MemberCheck
*
bool
`url:"member_check,omitempty" json:"member_check
,omitempty
"`
PreventSecrets
*
bool
`url:"prevent_secrets,omitempty" json:"prevent_secrets
,omitempty
"`
MaxFileSize
*
int
`url:"max_file_size,omitempty" json:"max_file_size
,omitempty
"`
}
// EditProjectPushRule edits a push rule for a specified project.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment