> For the complete documentation index, see [llms.txt](https://docs.runway.team/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.runway.team/integrations/ci-cd/github-actions.md).

# GitHub Actions

<div align="left"><img src="https://727226624-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MjFmyReUsbJqDjHEAlW%2F-MjH7SeMEkuedQqH2j3U%2F-MjH7sQqcDycHAdAvBKZ%2Fgithub.png?alt=media&amp;token=83ae9d71-08c1-4563-aad5-256e34756b3c" alt=""></div>

## Set up

### Navigate to the Integration settings view

1. Select an app in the top left corner from the Switcher
2. Navigate to **App Settings** by clicking the gear icon (⚙️) at the top of the Timeline sidebar
3. Click on **Integrations** in the sidebar

### Connect GitHub Actions

* Find the **GitHub Actions** integration module under the **CI/CD** section
* Click the **Connect** button. You’ll be taken through a standard [GitHub app](https://developer.github.com/apps/) OAuth flow. (Or, you’ll be given the option to reuse the GitHub connection you already established when setting up GitHub for version control.)
* GitHub redirects you back to Runway
  * Select the name of your repo from the list of options
  * Select the name of your Release Candidate workflow from the list of options

{% hint style="warning" %}
If your team uses static branches, your workflow run name must include the version — see [workflow run names](#workflow-run-names).
{% endhint %}

* Optionally, enter the name of your release workflow (the one that generates the builds that you end up submitting to the App Store/Play Store) if it’s different than your Release Candidate workflow
* Optionally, enter the name of the deploy branch on which your release workflows are triggered, if this branch is different than the branch your Release Candidate workflow is triggered on
* Optionally, enter [workflow arguments](#workflow-arguments) for any of the above workflows

{% hint style="info" %}
Learn more about [builds and branches in Runway](/getting-started/setting-up-mobile-release-management/setting-up-your-integrations/builds-and-branches.md).
{% endhint %}

### Triggering builds from Runway

In order to trigger builds from Runway, your GitHub Actions workflow will need to have `workflow_dispatch` configured. See GitHub’s [documentation](https://docs.github.com/en/actions/reference/workflows-and-actions/events-that-trigger-workflows#workflow_dispatch) for more info.

### Workflow arguments

Workflow arguments (a.k.a. "inputs" or "trigger variables") are key-value pairs you can enter for any of your configured workflows. Runway uses them in two ways:

* **Triggering builds**: when you trigger a build from within Runway, Runway passes your arguments in its calls to the GitHub API.
* **Filtering builds**: Runway can filter the builds it fetches based on workflow arguments. This can be useful if you use the same workflow for multiple different build types and the specific build type that's built is determined by one or more workflow arguments. To filter builds, your arguments must be included in the [workflow run name](#workflow-run-names).

### Workflow run names

{% hint style="warning" %}
If your team uses static branches, your workflow run name must include the version (e.g. `version=12.13.0`) so that Runway can identify the version properly.
{% endhint %}

Because the GitHub API does not return workflow arguments in its build responses, Runway reads certain information from each build's [run name](https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#run-name) instead. Depending on your setup, your run name needs to include:

* **Workflow arguments**, if you want Runway to filter builds based on them
* **The version**, if your team uses static branches, so that Runway can identify the version properly

#### Format

Values in the run name must be separated by spaces and use the notation `key=value`, e.g. `pilot=Sully` or `pilot='Sully B.'` (wrap any keys or values that contain spaces in single quotes).

* Valid: `Workflow pilot=Sully age=50`
* Not valid: `Workflow (pilot=Sully, age=50)`

For teams using static branches, include the version using the `version` key:

* Valid: `Workflow pilot=Sully version=12.13.0`
