Conditional merge check: read pathsMatch and mandatory reviewer from a file in repo

Deepu October 5, 2018

Requirement is to read the source code folder path and its corresponding mandatory reviewer from an input file which is already version controlled in GIT repo master branch. Then enable merge button only if at least one mandatory reviewer has approved the PR for the corresponding source code folder path under review as part of the PR. A PR may contain multiple folder paths, so the check should happen for all edited paths maybe in a loop.

 

Input file format:

-----------------------------------------

src/test/module1 : mandatory-reviewer1,mandatory-reviewer

src/test/module2 : mandatory-reviewer3,mandatory-reviewer4 

-----------------------------------------

 

Please help with the code snippet or some pointers. I tried few searches, but could not find the needed info.

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events