mirror of
https://github.com/harness/drone.git
synced 2025-05-31 11:43:15 +00:00
fix missing commit sha and wrong tag link.
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
This commit is contained in:
parent
0c972d8fc5
commit
2a2ff0550c
@ -100,9 +100,9 @@ func buildFromTag(hook *pushHook) *model.Build {
|
||||
|
||||
return &model.Build{
|
||||
Event: model.EventTag,
|
||||
Commit: hook.After,
|
||||
Commit: hook.Sha,
|
||||
Ref: fmt.Sprintf("refs/tags/%s", hook.Ref),
|
||||
Link: fmt.Sprintf("%s/src/%s", hook.Repo.URL, hook.Ref),
|
||||
Link: fmt.Sprintf("%s/src/tag/%s", hook.Repo.URL, hook.Ref),
|
||||
Branch: fmt.Sprintf("refs/tags/%s", hook.Ref),
|
||||
Message: fmt.Sprintf("created tag %s", hook.Ref),
|
||||
Avatar: avatar,
|
||||
|
@ -1,6 +1,7 @@
|
||||
package gitea
|
||||
|
||||
type pushHook struct {
|
||||
Sha string `json:"sha"`
|
||||
Ref string `json:"ref"`
|
||||
Before string `json:"before"`
|
||||
After string `json:"after"`
|
||||
|
Loading…
x
Reference in New Issue
Block a user