Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Choose not to auto-merge

Lucid Software November 3, 2014

Automatically merging based on version numbers is cool. But I don't always want to do that.

Occasionally, there will be a change that should only go into the production branch, but not the development one.

For example, suppose I to adjust the database connection pool to compensate for a bug in production. The bug has been fixed in development, so no workaround commit is needed on the development branch.

What is best way to selectively not auto-merge?

Screenshot from 2014-11-04 01:15:26.png

2 answers

1 accepted

1 vote
Answer accepted
Lucid Software November 4, 2014

I don't think it's feasible to not auto-merge, as that would cause the changes to be picked up on the next similar pull request.

But I believe it work to "pre-merge" with the "ours" strategy.

git checkout branch-to-exclude
git merge -s ours PROJECT-123

and push.

The merge will still happen, but it won't take any changes from the branch.

Adam
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 4, 2014

Yup - that's the best way to do it. :) I created a JIRA that you may be interested in following for us to add UI that supports this https://jira.atlassian.com/browse/STASH-5356

Lucid Software November 4, 2014

@Adam Ahmed , thanks for the confirmation! (I thought I was pretty clever to figure this out....glad to see I'm not alone.)

0 votes
Adam
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 4, 2014

For Google's benefit, linking to a similar question and answer https://answers.atlassian.com/questions/9390955/answers/9390961/comments/9394426

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events