Skip to content

Commit

Permalink
Merge pull request #23198 from storybookjs/release-tooling-simpler-ci
Browse files Browse the repository at this point in the history
Build: Don't auto-trigger CI on release PRs
(cherry picked from commit 1d61076)
  • Loading branch information
JReinhold authored and github-actions[bot] committed Jun 26, 2023
1 parent 861c511 commit 7887337
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 7 deletions.
6 changes: 2 additions & 4 deletions .github/workflows/trigger-circle-ci-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ on:
branches:
- next
- main
- version-prerelease-from-**
- version-patch-from-**

jobs:
get-branch:
Expand Down Expand Up @@ -56,7 +54,7 @@ jobs:
trigger-pr-tests:
runs-on: ubuntu-latest
needs: get-branch
if: github.event_name == 'pull_request_target' && ((github.event.pull_request.draft == false || contains(github.event.pull_request.labels.*.name, 'ci:pr')) && !contains(github.event.pull_request.labels.*.name, 'ci:merged') && !contains(github.event.pull_request.labels.*.name, 'ci:daily'))
if: github.event_name == 'pull_request_target' && (((github.event.pull_request.draft == false && !contains(github.event.pull_request.labels.*.name, 'release')) || contains(github.event.pull_request.labels.*.name, 'ci:pr')) && !contains(github.event.pull_request.labels.*.name, 'ci:merged') && !contains(github.event.pull_request.labels.*.name, 'ci:daily'))
steps:
- name: Trigger PR tests
run: >
Expand Down Expand Up @@ -109,4 +107,4 @@ jobs:
}'
env:
CIRCLE_CI_TOKEN: ${{ secrets.CIRCLE_CI_TOKEN }}
BRANCH: ${{ needs.get-branch.outputs.branch }}
BRANCH: ${{ needs.get-branch.outputs.branch }}
20 changes: 18 additions & 2 deletions scripts/release/__tests__/generate-pr-description.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ For each pull request below, you need to either manually cherry pick it, or disc
Before merging the PR, there are a few QA steps to go through:
- [ ] Add the \\"freeze\\" label to this PR, to ensure it doesn\\'t get automatically forced pushed by new changes.
- [ ] Add the \\"ci:daily\\" label to this PR, to trigger the full test suite to run on this PR.
And for each change below:
Expand Down Expand Up @@ -235,6 +236,13 @@ For each pull request below, you need to either manually cherry pick it, or disc
"This is an automated pull request. None of the changes requires a version bump, they are only internal or documentation related. Merging this PR will not trigger a new release, but documentation will be updated.
If you\\'re not a core maintainer with permissions to release you can ignore this pull request.
## To do
Before merging the PR:
- [ ] Add the \\"freeze\\" label to this PR, to ensure it doesn\\'t get automatically forced pushed by new changes.
- [ ] Add the \\"ci:daily\\" label to this PR, to trigger the full test suite to run on this PR.
This is a list of all the PRs merged and commits pushed directly to \\\`next\\\` since the last release:
- **🐛 Bug**: Some PR title for a bug [#42](https://github.com/storybookjs/storybook/pull/42)
Expand Down Expand Up @@ -263,7 +271,7 @@ For each pull request below, you need to either manually cherry pick it, or disc
- [ ] [#42](https://github.com/storybookjs/storybook/pull/42): \\\`git cherry-pick -m1 -x abc123\\\`
If you\\'ve made any changes (change PR titles, revert PRs), manually trigger a re-generation of this PR with [this workflow](https://github.com/storybookjs/storybook/actions/workflows/prepare-prerelease.yml) and wait for it to finish.
If you\\'ve made any changes (change PR titles, revert PRs), manually trigger a re-generation of this PR with [this workflow](https://github.com/storybookjs/storybook/actions/workflows/prepare-patch-release.yml) and wait for it to finish.
When everything above is done:
- Merge this PR
Expand Down Expand Up @@ -294,6 +302,7 @@ For each pull request below, you need to either manually cherry pick it, or disc
Before merging the PR, there are a few QA steps to go through:
- [ ] Add the \\"freeze\\" label to this PR, to ensure it doesn\\'t get automatically forced pushed by new changes.
- [ ] Add the \\"ci:daily\\" label to this PR, to trigger the full test suite to run on this PR.
And for each change below:
Expand Down Expand Up @@ -350,6 +359,13 @@ For each pull request below, you need to either manually cherry pick it, or disc
"This is an automated pull request. None of the changes requires a version bump, they are only internal or documentation related. Merging this PR will not trigger a new release, but documentation will be updated.
If you\\'re not a core maintainer with permissions to release you can ignore this pull request.
## To do
Before merging the PR:
- [ ] Add the \\"freeze\\" label to this PR, to ensure it doesn\\'t get automatically forced pushed by new changes.
- [ ] Add the \\"ci:daily\\" label to this PR, to trigger the full test suite to run on this PR.
This is a list of all the PRs merged and commits pushed directly to \\\`next\\\` since the last release:
- **🐛 Bug**: Some PR title for a bug [#42](https://github.com/storybookjs/storybook/pull/42)
Expand All @@ -373,7 +389,7 @@ For each pull request below, you need to either manually cherry pick it, or disc
If you\\'ve made any changes (change PR titles, revert PRs), manually trigger a re-generation of this PR with [this workflow](https://github.com/storybookjs/storybook/actions/workflows/prepare-prerelease.yml) and wait for it to finish.
If you\\'ve made any changes (change PR titles, revert PRs), manually trigger a re-generation of this PR with [this workflow](https://github.com/storybookjs/storybook/actions/workflows/prepare-patch-release.yml) and wait for it to finish.
When everything above is done:
- Merge this PR
Expand Down
10 changes: 9 additions & 1 deletion scripts/release/generate-pr-description.ts
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ export const generateReleaseDescription = ({
Before merging the PR, there are a few QA steps to go through:
- [ ] Add the "freeze" label to this PR, to ensure it doesn't get automatically forced pushed by new changes.
- [ ] Add the "ci:daily" label to this PR, to trigger the full test suite to run on this PR.
And for each change below:
Expand Down Expand Up @@ -198,13 +199,20 @@ export const generateNonReleaseDescription = (
dedent`This is an automated pull request. None of the changes requires a version bump, they are only internal or documentation related. Merging this PR will not trigger a new release, but documentation will be updated.
If you're not a core maintainer with permissions to release you can ignore this pull request.
## To do
Before merging the PR:
- [ ] Add the "freeze" label to this PR, to ensure it doesn't get automatically forced pushed by new changes.
- [ ] Add the "ci:daily" label to this PR, to trigger the full test suite to run on this PR.
This is a list of all the PRs merged and commits pushed directly to \`next\` since the last release:
${changeList}
${manualCherryPicks || ''}
If you've made any changes (change PR titles, revert PRs), manually trigger a re-generation of this PR with [this workflow](https://github.com/storybookjs/storybook/actions/workflows/prepare-prerelease.yml) and wait for it to finish.
If you've made any changes (change PR titles, revert PRs), manually trigger a re-generation of this PR with [this workflow](https://github.com/storybookjs/storybook/actions/workflows/prepare-patch-release.yml) and wait for it to finish.
When everything above is done:
- Merge this PR
Expand Down

0 comments on commit 7887337

Please sign in to comment.