Is there any description on how to properly ‘migrate’ my own engine changes between engine versions ?
For example I’m working with 4.12 from github, and added some new features to the renderer / shader editor, wrote new postprocessing nodes, etc. (all in c++/*.usf).
There is no problem while updating when new hotfix is released for 4.12, (I’m pulling from remote branch into my own and git merges changes).
Now how to migrate all my changes to the new 4.13 branch from github ?
Just doing Pull from 4.13 branch into my 4.12_modified_by_me branch seems like a bad idea (the number of conflicts goes into 100’s of files (many more than I’v edited anyway))
Generating ‘patch’ (using any diff tool) between original 4.12 & 4.12_modified_by_me, then trying to apply this patch to fetched 4_13 generates far less conflicts to resolve, but still it’s not an ideal solution, any other methods ?
What we tend to do is we have a local mirror branch (let’s call it ‘ue4-base’) of the main UE4 branches (we started at 4.10 or something). The first thing we did was create a branch from that base version (e.g. ‘ue4-ours’) and started working on modifications there. Now when we want to update, we first update our ue4-base to the latest version epic provides (this shouldn’t cause any conflicts as we don’t have any local changes there), and then merge that branch into ‘ue4-ours’; we might get some conflicts in that process (but only in files we’ve touched).
What you definitely don’t want to do is generate a patch, apply that and fix the conflicts manually. You’ll have permanently robbed git of the necessary merge links it needs to resolve future conflicts and merges, sure you might get it to work but the problem will be larger (and continue getting larger) in the future.
It seems you’re missing some step in your merging process (you definitely shouldn’t be getting conflicts outside of the files you’ve touched yourself). What I’d suggest is, in your local repository, make a new branch based on the commit of the initial 4.12 version you started diverging from (lets call it ‘4.13-merge’, then pull all the hotfixes you’ve pulled into your ‘4.12_modified_by_me_branch’ into that branch (presumably you were on the latest 4.12 hotfix and pulled all of the ones since the original branch creation, if so you can probably just pull from remote once). From there, try to merge the 4.13 branch into that branch and see if you still get commits. If you do- something over at epic may have gone awry (it would suggest the 4.12 hotfix commits never made it into the 4.13 branch). If that happens it’d be good to get a view of your git tree or something (with redacted commit messages if that’s a concern). If you don’t; try merging the ‘4.13-merge’ branch into your ‘4.12_modified_by_me’ and see if that works better.
Hope that helps.