Liftbay

Build triggers

Start builds on push, pull request and tag, with status on GitHub.

With the GitHub App installed, builds can start on their own when you push, open a pull request or push a tag. Add triggers to liftbay.json:

liftbay.json
{
  "build": {
    "profiles": {
      "preview": { "environment": "preview", "distribution": "internal", "platforms": ["ios", "android"] },
      "production": { "environment": "production", "distribution": "store", "platforms": ["ios", "android"] }
    },
    "triggers": [
      { "on": "push", "branches": ["main"], "profile": "production" },
      { "on": "pull_request", "branches": ["main"], "profile": "preview", "platforms": ["android"] },
      { "on": "tag", "tags": ["v*"], "profile": "production", "submit": true }
    ]
  }
}

Liftbay reads liftbay.json at the commit that was pushed, so a change to the triggers applies from that commit on.

Trigger fields

FieldMeaning
onpush (to a branch), pull_request (opened, new commits, reopened) or tag
branchespush: the branch pushed to. pull_request: the base branch. Default: any
tagstag: the tag name. Default: any
profileThe build profile to use (its environment and distribution)
platformsDefault: the profile's platforms
submitSubmit to the store when the build succeeds

Branch and tag patterns are globs: * matches within one path segment (release/* matches release/1.6), ** across segments (release/** matches release/1.6/hotfix), ? one character.

What never builds

  • Commits whose message, or pull requests whose title, contains [skip ci], [ci skip] or [liftbay skip].
  • Pull requests from forks: they would run someone else's code with your project's secrets.
  • Deleted branches and tags.
  • A commit already built with the same profile and platform (for example a push and a pull request for the same commit).

npx liftbay ci init writes an empty triggers list; nothing builds on its own until you add one.

Status on GitHub

Each build from a commit reports a commit status, named Liftbay / Android (production) or Liftbay / iOS (preview). It shows next to the commit and in the pull request's checks, links to the build in the dashboard, and moves from pending to success, failure or error (cancelled).

Use it as a required status check in branch protection to block merges until the build passes.

Existing installations

Triggers need the app's push and pull_request events and the Commit statuses: write permission. If you installed the app before these were added, GitHub asks an organization owner to approve the new permission in the installation's settings.

On this page