Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for github pull request comment webhook parsing #33

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

jstrachan
Copy link

No description provided.

@CLAassistant
Copy link

CLAassistant commented Jul 4, 2019

CLA assistant check
All committers have signed the CLA.

return nil, err
}
dst := convertPullRequestReviewCommentHook(src)
return dst, nil
Copy link
Member

@bradrydzewski bradrydzewski Jul 9, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this function should set the action to one of scm.ActionCreate, scm.ActionUpdate, scm.ActionDelete

@@ -356,6 +391,35 @@ func convertPullRequestHook(src *pullRequestHook) *scm.PullRequestHook {
}
}

func convertPullRequestReviewCommentHook(src *pullRequestReviewCommentHook) *scm.PullRequestCommentHook {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this should return a ReviewCommentHook. The distinction is that a pull request comment is when you comment on the issue (although github treats pull requests the same as issues, other providers do not, so we abstract). The review comment is when you comment on code. The ReviewCommentHook also stores a Review information such as file name and line number.

jstrachan pushed a commit to jstrachan/go-scm that referenced this pull request Oct 2, 2019
fix: avoid failures on bitbucket cluster
@chhsia0
Copy link
Contributor

chhsia0 commented Oct 24, 2019

Is this going stale? I'm currently using go-github to parse issue comments for pull requests but considering to add such support for go-scm. Is the intention of this PR to support review comment or issue comments on pull requests? Should I wait for this PR? Thanks for an update :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants