Skip to content
git-merge

GitHub Action

Check staged

v1.0 Latest version

Check staged

git-merge

Check staged

Checks if a branch has been merged to staging

Installation

Copy and paste the following snippet into your .yml file.

              

- name: Check staged

uses: jack-lewin/[email protected]

Learn more about this action in jack-lewin/check-staged

Choose a version

check-staged

This action checks that the source branch of a PR has been merged into a staging branch.

Inputs

  • staging-branch

The name of the staging branch you'd like to check. Defaults to staging.

Outputs

The check will pass if the latest commit in the PR has been merged into the staging branch.

Example usage

See https://github.com/jack-lewin/demo-check-staging for a real example.

# .github/workflows/check-branch-is-staged.yml

on: pull_request

jobs:
  check-branch-is-staged:
    name: Check the branch is staged before it can be merged
    runs-on: ubuntu-latest
    steps:
      - uses: jack-lewin/[email protected]
        with:
          staging-branch: 'dev'