1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-25 03:20:23 +01:00
metamask-extension/.github/workflows/add-release-label.yml

41 lines
1.2 KiB
YAML
Raw Normal View History

feat(action): github action to automatically add label "release-x.y.z" when PRs get merged (#19061) * feat(action): github action to add release label when PR gets merged * feat(action): make sure the action only runs for PRs merged in main branch * fix(action): update labels default color * fix(action): add check on release label format * fix(action): type function explicitely * feat(action): add possibility to extract next release version number from artifact * fix(action): rename next rc cut number into next semver version * feat(action): add a github action to create release branch * fix(action): default branch is develop * fix(action): specify name of workflow used to create release branch * fix(action): handle case where artifact doesn't exist * fix(action): create branch but not the PR * feat(action): fetch next semver version from release branches name or from package.json * fix(action): remove unused Create Release Branch action * fix(action): release branch format was not correct * feat(action): take tags into account when calculating next version number * feat(action): add the possibility to force next semver version * fix(action): update comments * fix(action): adopt kebak-case instead of snake_case * fix(action): rename PERSONAL_ACCESS_TOKEN into RELEASE_LABEL_TOKEN * fix(action): yarn installation not required * fix(action): yarn install shall be immutable * fix(action): make the script compatible with ShellCheck * fix(script): exit script earlier if condition is met * fix(action): use closingIssuesReferences instead of timeline events * fix(action): add execute permissions to script * fix(action): remove duplicate comment
2023-06-20 14:29:35 +02:00
name: Add release label to PR and linked issues when PR gets merged
on:
pull_request:
branches:
- develop
types:
- closed
jobs:
add-release-label:
runs-on: ubuntu-latest
if: github.event.pull_request.merged == true
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 0 # This is needed to checkout all branches
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version-file: '.nvmrc'
cache: yarn
feat(action): github action to automatically add label "release-x.y.z" when PRs get merged (#19061) * feat(action): github action to add release label when PR gets merged * feat(action): make sure the action only runs for PRs merged in main branch * fix(action): update labels default color * fix(action): add check on release label format * fix(action): type function explicitely * feat(action): add possibility to extract next release version number from artifact * fix(action): rename next rc cut number into next semver version * feat(action): add a github action to create release branch * fix(action): default branch is develop * fix(action): specify name of workflow used to create release branch * fix(action): handle case where artifact doesn't exist * fix(action): create branch but not the PR * feat(action): fetch next semver version from release branches name or from package.json * fix(action): remove unused Create Release Branch action * fix(action): release branch format was not correct * feat(action): take tags into account when calculating next version number * feat(action): add the possibility to force next semver version * fix(action): update comments * fix(action): adopt kebak-case instead of snake_case * fix(action): rename PERSONAL_ACCESS_TOKEN into RELEASE_LABEL_TOKEN * fix(action): yarn installation not required * fix(action): yarn install shall be immutable * fix(action): make the script compatible with ShellCheck * fix(script): exit script earlier if condition is met * fix(action): use closingIssuesReferences instead of timeline events * fix(action): add execute permissions to script * fix(action): remove duplicate comment
2023-06-20 14:29:35 +02:00
- name: Install dependencies
run: yarn --immutable
- name: Get the next semver version
id: get-next-semver-version
env:
FORCE_NEXT_SEMVER_VERSION: ${{ vars.FORCE_NEXT_SEMVER_VERSION }}
run: ./development/get-next-semver-version.sh "$FORCE_NEXT_SEMVER_VERSION"
feat(action): github action to automatically add label "release-x.y.z" when PRs get merged (#19061) * feat(action): github action to add release label when PR gets merged * feat(action): make sure the action only runs for PRs merged in main branch * fix(action): update labels default color * fix(action): add check on release label format * fix(action): type function explicitely * feat(action): add possibility to extract next release version number from artifact * fix(action): rename next rc cut number into next semver version * feat(action): add a github action to create release branch * fix(action): default branch is develop * fix(action): specify name of workflow used to create release branch * fix(action): handle case where artifact doesn't exist * fix(action): create branch but not the PR * feat(action): fetch next semver version from release branches name or from package.json * fix(action): remove unused Create Release Branch action * fix(action): release branch format was not correct * feat(action): take tags into account when calculating next version number * feat(action): add the possibility to force next semver version * fix(action): update comments * fix(action): adopt kebak-case instead of snake_case * fix(action): rename PERSONAL_ACCESS_TOKEN into RELEASE_LABEL_TOKEN * fix(action): yarn installation not required * fix(action): yarn install shall be immutable * fix(action): make the script compatible with ShellCheck * fix(script): exit script earlier if condition is met * fix(action): use closingIssuesReferences instead of timeline events * fix(action): add execute permissions to script * fix(action): remove duplicate comment
2023-06-20 14:29:35 +02:00
- name: Add release label to PR and linked issues
id: add-release-label-to-pr-and-linked-issues
env:
RELEASE_LABEL_TOKEN: ${{ secrets.RELEASE_LABEL_TOKEN }}
NEXT_SEMVER_VERSION: ${{ env.NEXT_SEMVER_VERSION }}
run: yarn run add-release-label-to-pr-and-linked-issues