The update process will be different depending on how you acquired the UnrealEngine repository.
##Direct clone
If you cloned directly from EpicGames/UnrealEngine, you can simply update by pulling the latest commits:
git pull
And then checking out the version tag you’re interested in:
git checkout 4.1
##Fork
If you forked, you will have a remote branch named origin
which points to the version of your repository as it currently exists on the GitHub servers. Note, however, that your fork is disconnected from Epic’s version of the repository – we need to remedy that.
If you have not already done so, define a new remote branch pointing to Epic’s UnrealEngine repo:
git remote add upstream https://github.com/EpicGames/UnrealEngine.git
Now fetch the most up-to-date data from the upstream
branch:
git fetch upstream
Once that completes, you’re ready to merge in whichever version of the upstream branch that you want. To merge in the latest version 4.1 changes:
git merge upstream/4.1
If any conflicts were encountered while merging, resolve them:
git mergetool
You then need to commit the new changes:
git commit -m "Updated to version 4.1"
For more on working with forks, please refer to GitHub’s documentation: Fork a repo - GitHub Docs
##Required binaries
Required dependencies do not get updated automatically when you pull the latest changes from GitHub. It is likely that these zip files will change between releases, so you will need to manually download the latest versions and re-extract them into your local workspace.
You may safely overwrite old source repos, but in practice you shouldn’t have to. When you pull the latest changes from GitHub, all local source code will be updated to the most recent version. The simplest workflow is to work from a single repo clone and do all updating in-place. You shouldn’t need to generate multiple copies of your cloned repos unless you have a compelling reason to do so.
Given the manual nature of required binary zip files, you may accumulate some clutter in folders not governed by the repository (such as those created during zip file extraction), but it shouldn’t be a major concern. We are hoping to improve this part of the process in the future.