We are facing situation below:
we use Bitbucket add-on "workzone" and set "unapprove alll approvals upon new commit goes into pull request"
meanwhile, we use "branch updater" auto-merge model for bamboo tests, which means any new commits from master will be pushed to review branches, this will be a new commit showing in pull request, this action will also unapprove all existing approvals......
That is what we want, we only want pushes from developer to trigger unapproval, but merges from bamboo shouldn't trigger it.
How can I achieve this? I am thinking about writing an external hook, which will run a .sh to judge if the commit is from developer or bamboo account, then do / not do an unapproval. Will this work? Or is there any off-the-shelf add-on we can use?
ps: we do not to modify the way developers writing their commit msg, so we will not accepting putting a "#keep" or a "#unapprove" in commit msg to achieve this...