Skip to content

Commit

Permalink
Merge pull request #82 from jlehtimaki/add_after_and_before_values
Browse files Browse the repository at this point in the history
Added before and after values to show before and after commitids on push
  • Loading branch information
bradrydzewski authored Nov 11, 2020
2 parents 5230330 + 6194ed1 commit c0438b4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions scm/driver/stash/testdata/webhooks/push.json.golden
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
"Ref": "refs/heads/master",
"After": "823b2230a56056231c9425d63758fa87078a66b4",
"Before": "5c64a07cd6c0f21b753bf261ef059c7e7633c50a",
"Repo": {
"ID": "1",
"Namespace": "PRJ",
Expand Down
2 changes: 2 additions & 0 deletions scm/driver/stash/webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,8 @@ func convertPushHook(src *pushHook) *scm.PushHook {
}
return &scm.PushHook{
Ref: change.RefID,
After: change.ToHash,
Before: change.FromHash,
Commit: scm.Commit{
Sha: change.ToHash,
Message: "",
Expand Down

0 comments on commit c0438b4

Please sign in to comment.