-
-
Notifications
You must be signed in to change notification settings - Fork 0
chore: splitting icons into standalone components #55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -22,80 +22,12 @@ on: | |
| - minor | ||
| - major | ||
|
|
||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
|
|
||
| concurrency: | ||
| group: "release" | ||
| cancel-in-progress: false | ||
|
|
||
| jobs: | ||
| release: | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v6 | ||
|
|
||
| - name: "Update Dev Container Index" | ||
| run: bash ./scripts/update-data.sh | ||
|
|
||
| - name: "Bump to new version" | ||
| id: bump | ||
| run: | | ||
| _version=$(npm --no-git-tag-version version ${{ github.event.inputs.version || 'patch' }}) | ||
|
|
||
| echo "new_version=$_version" >> $GITHUB_OUTPUT | ||
| echo "New version: $_version" | ||
|
|
||
| - name: "Create Pull Request" | ||
| id: cpr | ||
| uses: peter-evans/create-pull-request@v8 | ||
| with: | ||
| token: ${{ secrets.RELEASE_PAT }} | ||
| title: "chore(release): bump version to ${{ env.NEW_VERSION }}" | ||
| body: "chore(release): bump version to ${{ env.NEW_VERSION }}" | ||
| commit-message: "chore(release): bump version to ${{ env.NEW_VERSION }}" | ||
| branch: "release-${{ env.NEW_VERSION }}" | ||
| delete-branch: true | ||
| env: | ||
| NEW_VERSION: ${{ steps.bump.outputs.new_version }} | ||
|
|
||
| - name: "Auto-merge PR" | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| run: | | ||
| gh pr merge --squash --auto "${{ steps.cpr.outputs.pull-request-number }}" | ||
|
|
||
| - name: "Wait for PR to merge" | ||
| if: steps.cpr.outputs.pull-request-number != '' | ||
| timeout-minutes: 3 | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| PR_NUMBER: ${{ steps.cpr.outputs.pull-request-number }} | ||
| run: | | ||
| while true; do | ||
| STATE=$(gh pr view "$PR_NUMBER" --json state --template '{{.state}}') | ||
| if [ "$STATE" == "MERGED" ]; then | ||
| echo "PR merged." | ||
| break | ||
| fi | ||
| if [ "$STATE" == "CLOSED" ]; then | ||
| echo "PR closed without merging." | ||
| exit 1 | ||
| fi | ||
| echo "State: $STATE. Waiting 3s..." | ||
| sleep 3 | ||
| done | ||
|
|
||
| - name: "Release" | ||
| if: steps.cpr.outputs.pull-request-number != '' | ||
| env: | ||
| # https://docs.github.com/en/actions/how-tos/write-workflows/choose-when-workflows-run/trigger-a-workflow#triggering-a-workflow-from-a-workflow | ||
| GITHUB_TOKEN: ${{ secrets.RELEASE_PAT }} | ||
| NEW_VERSION: ${{ steps.bump.outputs.new_version }} | ||
| run: | | ||
| gh release create $NEW_VERSION \ | ||
| --target main \ | ||
| -t $NEW_VERSION | ||
| uses: drehelis/improved-chainsaw/.github/workflows/release.yml@main | ||
| with: | ||
| version: ${{ github.event.inputs.version || 'patch' }} | ||
| pre_release_command: "bash ./scripts/update-data.sh" | ||
| timeout_minutes: 5 | ||
| secrets: inherit | ||
|
Comment on lines
26
to
+33
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The reusable workflow is referenced by branch (
@main). For security and supply-chain safety, pin reusable workflow references to an immutable tag or commit SHA so a future change onmaincannot unexpectedly alter your release process.