You want to merge this change as not merged, but mark it that way in history. This way you will find out where to get subsequent changes.
There are several ways to do this. One of them -
git checkout master git merge -s ours --no-ff testing git checkout testing git merge -s ours --no-ff master
or
git checkout master git merge testing --no-commit --no-ff git checkout HEAD -- . git submodule update
Now you have 2 branches with different configurations, but those that are committed are in front of the important merge-base .
Now you need the script to do something similar to perform a special merge, which is actually a submenu at the bottom - this is the only way to ignore what it was before:
git checkout master git merge --no-ff -s ours testing git checkout -b temp testing git rebase -s recursive -Xtheirs master
It just minimizes what you don't have branches testing on the server and makes it look like a merge. Since it stores it as a merge, you can subsequently run it against other branches that you want to publish in order to execute the wizard. Thus, you can separate all of these commands with && s, replace testing with an argument, a wizard with second argument variables, and an alias:
git config alias.smart-merge '...'
so you can post these changes:
git smart-merge testing master git smart-merge feature2 master
which should give you both testing and function2, no matter at what point these 2 can already be combined in history.
Also consider enabling reerere as the script does not expect conflicts. Therefore, if you want to publish, you can perform a normal reboot first, recording conflict resolution. You can now modify the script to take advantage of these and not break conflicts.
Restoring conflict resolution can be a pain. But not in this case, since we use only the wizard for publication. Other branch manipulations are still performed using regular merge or redirection.
- OR -
Nontrivial - these are pure smudge scripts. Take a look at the git attribute section in progit.org/book.
Hope this helped.