Matrix Blueprints

Matrix game blueprints provide a streamlined way to configure common attributes across multiple builds. For instance, when exporting when compiling godot for Android and Linux, each platform shares common elements like the Git repository and Git reference, but they vary in platform, cpu architecture and build target

This is where the matrix becomes incredibly useful. You can set up the common attributes in the matrix configuration while specifying the unique details for each job.

Why Use Matrix Operations?

  1. Efficiency: By running multiple jobs simultaneously, matrix operations reduce the time it takes to compile Godot to different platforms.

  2. Early Detection of Issues: With matrix builds, potential problems can be identified quickly across different scenarios, leading to faster fixes and higher code quality.

Create Godot Matrix

  1. Click “Matrix Blueprints” under the Triggers menu.

    Matrix home page
  2. Click “+ Create Godot matrix”

    Matrix home page
  3. Click the Cog icon button

    Matrix home page

Each field is:

Repository

The repository where the code for the engine is located. in this case Godot fork. Remember to add the full url, including .git

Git Ref

Anything pointing to a commit, branch name, tag name commit has. In this case, we tell to get the value with variable $.ref When using variables ($.ref), this matrix can only be triggered with a github event, cant be triggered manually since the variable will have an empty value

Scons flag

In this case we will be using custom_modules=special_modules, since we have a special module located on the folder special_modules Godot is compiled using scons. This field allows you to enter additional scons flag, this is a space separated list of key value pairs. Eg: verbose=yes

Godot Compilation profile

In this option select the recently godot build profile

the form should look like this

Matrix select profile

When adding a new job, we specify CPU, platform and build target. This way we complete all parameters needed for a complete build

Adding linux editor build

  1. Click “+ Add Job”

  2. Select “Linux” from 1st drop down

  3. Select “x86_64” from 2nd drop down

  4. Select “Editor” from 3rd drop down

    Matrix select profile

Adding Web template build

  1. Click “+ Add Job”

  2. Select “Web/Html5” from 1st drop down

  3. Select “Web Assembly 32” from 2nd drop down

  4. Select “Template release” from 3rd drop down

    Matrix select profile