You can install the build from any recent PR like you would install MG regularly by using the installer in the TeamCity artifacts from that PR. If you want to keep your installation at a specific version or if you intend to make changes, you should build from source. If you already build from source, the second option is very simple.
Go to the page of the PR you want to try and scroll to the bottom to find the build information. Click show all checks and then Details for the 'Package' check for your platform.
Go to the artifacts tab and click the installer you need to download it.
There you go! That's the same thing you download from the Downloads page from the MonoGame website. Run it like you normally would to get the MonoGame version of the PR installed.
If you don't have Git installed, do that first.
Clone MonoGame (or your fork of it) if you don't have a local copy yet and clone the submodules
$ git clone https://github.com/MonoGame/MonoGame.git
$ cd MonoGame
$ git submodule update --init
Add the remote of the owner of the PR you want to try (I always use some
short form of the users name for the remote name, we'll use a PR from me
as an example so I'd go with jjagg in this case).
You can see the name of the remote and the branch of a PR on GitHub at
the top. For this one it says: "Jjagg wants to merge 8 commits into
MonoGame:develop from Jjagg:instancedGL"
$ git remote add jjagg https://github.com/Jjagg/MonoGame.git
Fetch the branch you want to build from that remote and check it out
$ git fetch jjagg instancedGL
$ git checkout instancedGL
Run git status
.
Git may say something about dirty submodules. If that happens run
git submodule update
to check out the right commit for the submodules.
Run Protobuild.exe (in the MonoGame root folder) to generate the projects
and solutions (on Mac/Linux do mono Protobuild.exe
).
- If the PR applies to the ContentPipeline: Open the MonoGame.Framework solution for your platform, it will contain a project for the Pipeline Tool. Build the solution, set the Pipeline Tool project as the startup target and run it. Build your content like you normally would, MGCB and Content.Pipeline from the solution will be used with the changes from the branch you checked out.
- If the PR applies to the runtime framework: In the project you want to use this build with, add the MonoGame.Framework project for the platform you're targeting, delete the existing MonoGame.Framework reference on your project and add a reference to the MonoGame.Framework.[Platform] project you added instead. That's it! You can build and run your project.