[Backport 1.3.latest] Pin macos
runners to macos-12
(#1016)
#651
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# **what?** | |
# When a PR is merged, if it has the backport label, it will create | |
# a new PR to backport those changes to the given branch. If it can't | |
# cleanly do a backport, it will comment on the merged PR of the failure. | |
# | |
# Label naming convention: "backport <branch name to backport to>" | |
# Example: backport 1.0.latest | |
# | |
# You MUST "Squash and merge" the original PR or this won't work. | |
# **why?** | |
# Changes sometimes need to be backported to release branches. | |
# This automates the backporting process | |
# **when?** | |
# Once a PR is "Squash and merge"'d, by adding a backport label, this is triggered | |
name: Backport | |
on: | |
pull_request: | |
types: | |
- labeled | |
permissions: | |
contents: write | |
pull-requests: write | |
jobs: | |
backport: | |
name: Backport | |
runs-on: ubuntu-latest | |
# Only react to merged PRs for security reasons. | |
# See https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#pull_request_target. | |
if: > | |
github.event.pull_request.merged | |
&& contains(github.event.label.name, 'backport') | |
steps: | |
- uses: tibdex/[email protected] | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} |