Uploaded image for project: 'SR for Bitbucket - Development'
  1. SR for Bitbucket - Development
  2. SRBITB-405

Allow users to use the Hooks API to write custom merge checks

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Done
    • High
    • Resolution: Done
    • None
    • 5.6.3
    • None
    • None

    Description

      Currently merge checks work by adapting the new Hooks API merge check to look like the old one in scripts to preserve backwards compatibility.

      We need to expose the new Hooks API merge check in scripts so users can make use of it in custom ones.

      Requirements:

      • We should provide the PreRepositoryHookContext and the PullRequestMergeHookRequest in the "hookContext" and "hookRequest" script bindings respectively to get additional data related to the hook invocation.
      • Users should also be allowed to return a RepositoryHookResult to veto the merge and the veto messages should get displayed.
      • The old merge check scripts should still continue working.

      An example merge check can be found here.

      Attachments

        Activity

          People

            rlander Reece Lander
            amarkham Adam Markham
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: