How can I switch the UE4 source target of my project?

I had been working on a project created from a downloaded copy of the source. I realized I don’t really have a good solution for dealing with UE4 updates, so I forked the UE4 repository, cloned that locally, built UE4 again, and used the built editor to open the old project. Everything was cool until I realized that when I went to open the VS2013 project to see its code, it was still referencing the non-git copy of UE4.

Is there any way I can “port” the project to reference the version of UE4 that I would actually be able to update?

First, make sure the file associations and context menu options refer to the git repository build of the engine by running the following batch file as administrator:<git-repo>/Engine/Build/BatchFiles/RegisterShellCommands.bat

Once that’s done, browse to your .uproject file in Explorer, right-click it, and choose “Generate Visual Studio projects” from the context menu.

That did it! Thanks.

For anyone reading this and using 4.1 now that it has been released, the aforementioned batch file is no longer the way to go. What you want to do instead is run Engine/Binaries/Win64/UnrealVersionSelector-Win64-Shippping.exe.

Thanks, I was looking for that !

Sorry it is a little bit weird and complicated right now. We wanted to make sure that working with multiple versions of Unreal Engine is as easy as possible! Some teams may need to stay on particular versions to get their games finished, which is an crucial workflow that we will always accommodate. As you create various projects using multiple versions of our editor, we absolutely want to make sure projects and samples are clearly distinguished and your projects are super easy to update. We’ll do better next time. For the next release, we’ll try to make project management more consistent between GitHub versions and installed version, as well as make version management more transparent without sacrificing flexibility.