How do I make Jenkins see a Git merge commit as a change?
git, jenkins, merge
Solution
You can try to force always no fast-forward merges (`--no-ff` option) and all merges will produce even a merge-commit (not only when there are conflicts).
It also produce a more readable and clear git log.
BTW check if you have the last version of the Jenkins Git plugin (they had issues in the past).
Problem
Users A and B each make modifications (on different feature branches) to a particular repo. User A merges changes into staging branch. Jenkins builds the staging branch, and succeeds. User C (release manager for User B team) merges User B’s changes into staging branch. However, something in the merge goes wrong and isn’t noticed, such as a conflict that wasn’t resolved properly. Jenkins builds the staging branch, and fails because of the bad merge. Users A and B are notified of the build failure, because their code was part of the merge, even though their changes were not at fault. User C never gets a failure notice, even though his bad merge was what broke the build. Is there a way to: - Cause Jenkins to treat merge commits as changes? (There is the very real possibility that code will actually be modified during a merge!) - Notify User C (as the merge committer) along with users A and B? We are using the Git and Email-ext plugins for Jenkins. Edit, several months later: Still having issues with this — even in a scenario where the person who did the merge did not introduce breaking changes, it would still be nice for them to be notified that the build succeeded (or failed).