You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As we talked, I would like to implement Bitbucket support in Dispatch and pave the ground for other support such as GitLab. I browsed the code a bit and here is how I'm planning to implement it:
Add a configuration called provider where you can set either github or bitbucket (defaults to github for backward compatibility)
Move the Github webhook handling in Webhooks.Controller to his own Webhooks.GitHub module
Rename the :create action in Webhooks.Controller for :github which will call the Webhooks.GitHub module (and point the route to :github)
Create Webhooks.Bitbucket module for handling Bitbucket webhook
Add a POST :bitbucket action in Webhooks.Controller which uses the Webhooks.Bitbucket module with a route /webhooks/bitbucket
Add a BitbucketClient that implements ClientBehaviour.
Make sure that the Client module is used dependant on provider config variable.
Anything I forgot? Any recommandation?
The text was updated successfully, but these errors were encountered:
I think your plan covers the webhook and fetching repository metadata, which is 2/3 of the cycle. Have you look at the code that actually assign reviewers and post the comment in the PR stream?
As we talked, I would like to implement Bitbucket support in Dispatch and pave the ground for other support such as GitLab. I browsed the code a bit and here is how I'm planning to implement it:
provider
where you can set eithergithub
orbitbucket
(defaults to github for backward compatibility):create
action in Webhooks.Controller for:github
which will call the Webhooks.GitHub module (and point the route to :github):bitbucket
action in Webhooks.Controller which uses the Webhooks.Bitbucket module with a route/webhooks/bitbucket
provider
config variable.Anything I forgot? Any recommandation?
The text was updated successfully, but these errors were encountered: