BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
4e49f21b
Commit
4e49f21b
authored
Mar 13, 2015
by
Douwe Maan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set push data object kind in PushDataBuilder.
parent
606d24ff
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
7 deletions
+4
-7
create_tag_service.rb
app/services/create_tag_service.rb
+1
-3
git_tag_push_service.rb
app/services/git_tag_push_service.rb
+1
-3
push_data_builder.rb
lib/gitlab/push_data_builder.rb
+2
-1
No files found.
app/services/create_tag_service.rb
View file @
4e49f21b
...
...
@@ -40,9 +40,7 @@ class CreateTagService < BaseService
end
def
create_push_data
(
project
,
user
,
tag
)
data
=
Gitlab
::
PushDataBuilder
.
Gitlab
::
PushDataBuilder
.
build
(
project
,
user
,
Gitlab
::
Git
::
BLANK_SHA
,
tag
.
target
,
"
#{
Gitlab
::
Git
::
TAG_REF_PREFIX
}#{
tag
.
name
}
"
,
[])
data
[
:object_kind
]
=
"tag_push"
data
end
end
app/services/git_tag_push_service.rb
View file @
4e49f21b
...
...
@@ -16,8 +16,6 @@ class GitTagPushService
private
def
create_push_data
(
oldrev
,
newrev
,
ref
)
data
=
Gitlab
::
PushDataBuilder
.
build
(
project
,
user
,
oldrev
,
newrev
,
ref
,
[])
data
[
:object_kind
]
=
"tag_push"
data
Gitlab
::
PushDataBuilder
.
build
(
project
,
user
,
oldrev
,
newrev
,
ref
,
[])
end
end
lib/gitlab/push_data_builder.rb
View file @
4e49f21b
...
...
@@ -28,9 +28,10 @@ module Gitlab
# Get latest 20 commits ASC
commits_limited
=
commits
.
last
(
20
)
type
=
Gitlab
::
Git
.
tag_ref?
(
ref
)
?
"tag_push"
:
"push"
# Hash to be passed as post_receive_data
data
=
{
object_kind:
"push"
,
object_kind:
type
,
before:
oldrev
,
after:
newrev
,
ref:
ref
,
...
...
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