Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
java-gitlab-api
Project
Project
Details
Activity
Releases
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
沈俊林
java-gitlab-api
Commits
d4efbbe7
Commit
d4efbbe7
authored
May 02, 2016
by
Tim Olshansky
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #133 from jfisbein/master
Added support for tag_push_events on project hooks
parents
45f63e74
ae0c0926
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
1 deletion
+14
-1
GitlabAPI.java
src/main/java/org/gitlab/api/GitlabAPI.java
+2
-1
GitlabProjectHook.java
src/main/java/org/gitlab/api/models/GitlabProjectHook.java
+12
-0
No files found.
src/main/java/org/gitlab/api/GitlabAPI.java
View file @
d4efbbe7
...
...
@@ -1327,7 +1327,7 @@ public class GitlabAPI {
return
dispatch
().
to
(
tailUrl
,
GitlabProjectHook
.
class
);
}
public
GitlabProjectHook
addProjectHook
(
Serializable
projectId
,
String
url
,
boolean
pushEvents
,
boolean
issuesEvents
,
boolean
mergeRequestEvents
,
boolean
sslVerification
)
throws
IOException
{
public
GitlabProjectHook
addProjectHook
(
Serializable
projectId
,
String
url
,
boolean
pushEvents
,
boolean
issuesEvents
,
boolean
mergeRequestEvents
,
boolean
tagPushEvents
,
boolean
sslVerification
)
throws
IOException
{
String
tailUrl
=
GitlabProject
.
URL
+
"/"
+
sanitizeProjectId
(
projectId
)
+
GitlabProjectHook
.
URL
;
return
dispatch
()
...
...
@@ -1335,6 +1335,7 @@ public class GitlabAPI {
.
with
(
"push_events"
,
pushEvents
?
"true"
:
"false"
)
.
with
(
"issues_events"
,
issuesEvents
?
"true"
:
"false"
)
.
with
(
"merge_requests_events"
,
mergeRequestEvents
?
"true"
:
"false"
)
.
with
(
"tag_push_events"
,
tagPushEvents
?
"true"
:
"false"
)
.
with
(
"enable_ssl_verification"
,
sslVerification
?
"true"
:
"false"
)
.
to
(
tailUrl
,
GitlabProjectHook
.
class
);
}
...
...
src/main/java/org/gitlab/api/models/GitlabProjectHook.java
View file @
d4efbbe7
...
...
@@ -23,6 +23,9 @@ public class GitlabProjectHook {
@JsonProperty
(
"merge_requests_events"
)
private
boolean
mergeRequestsEvents
;
@JsonProperty
(
"tag_push_events"
)
private
boolean
tagPushEvents
;
@JsonProperty
(
"created_at"
)
private
Date
createdAt
;
...
...
@@ -77,6 +80,15 @@ public class GitlabProjectHook {
this
.
mergeRequestsEvents
=
mergeRequestsEvents
;
}
public
boolean
isTagPushEvents
()
{
return
tagPushEvents
;
}
public
void
setTagPushEvents
(
boolean
tagPushEvents
)
{
this
.
tagPushEvents
=
tagPushEvents
;
}
public
Date
getCreatedAt
()
{
return
createdAt
;
}
...
...
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