mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-09-05 18:01:32 +00:00
![dependabot[bot]](/assets/img/avatar_default.png)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
33 lines
1.1 KiB
YAML
33 lines
1.1 KiB
YAML
name: Backport PR on Label
|
|
|
|
on:
|
|
pull_request_target:
|
|
types:
|
|
- labeled
|
|
|
|
# Permissions needed for the korthout/backport-action to create branches and PRs
|
|
permissions:
|
|
contents: write
|
|
pull-requests: write
|
|
|
|
jobs:
|
|
backport:
|
|
name: Create Backport PR
|
|
runs-on: ubuntu-latest
|
|
if: |
|
|
github.event.pull_request.merged == true && startsWith(github.event.label.name, 'backport-')
|
|
steps:
|
|
- uses: actions/checkout@v5
|
|
with:
|
|
ref: ${{ github.event.pull_request.head.sha }}
|
|
token: ${{ steps.app-token.outputs.token }}
|
|
|
|
- name: Backport Action
|
|
uses: korthout/backport-action@v3
|
|
with:
|
|
# Regex pattern for labels that should trigger a backport AND extracts the target branch
|
|
# from the name (e.g. v0.x or v0.x.y; we use zerover). This action will ONLY proceed if
|
|
# the label that triggered the workflow fully matches this pattern.
|
|
# Example matching labels: "backport-v0.1", "backport-v0.10.1"
|
|
# Example non-matching labels: "backport-foo", "backport-v1.0"
|
|
label_pattern: '^backport-(v0\.\d+(\.\d+)?)$'
|