From 137dca53de484f8d0fdfa6f6d85c9b5be7fe8f79 Mon Sep 17 00:00:00 2001 From: jamiecobbett Date: Tue, 17 Feb 2026 12:43:11 +0000 Subject: [PATCH 1/2] Automatically create GH tags and releases --- .github/workflows/test-and-deplyo.yml | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test-and-deplyo.yml b/.github/workflows/test-and-deplyo.yml index 1e09094..d09bd05 100644 --- a/.github/workflows/test-and-deplyo.yml +++ b/.github/workflows/test-and-deplyo.yml @@ -3,7 +3,7 @@ on: push permissions: id-token: write # Required for OIDC - contents: read + contents: write # Required for creating releases and tags jobs: test: @@ -49,3 +49,23 @@ jobs: - run: npm install - name: Publish the library. run: npm publish $DIST_FOLDER + + create_release: + if: github.ref == 'refs/heads/master' + runs-on: ubuntu-latest + needs: + - publish_to_npm + steps: + - uses: actions/checkout@v3.3.0 + - name: Get version from package.json + id: version + run: echo "version=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT + - name: Create tag and release + run: | + git config user.name "github-actions[bot]" + git config user.email "github-actions[bot]@users.noreply.github.com" + git tag v${{ steps.version.outputs.version }} + git push origin v${{ steps.version.outputs.version }} + gh release create v${{ steps.version.outputs.version }} --generate-notes + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From bd874524b65b5b3ac18872a7d9608a027c8b70c5 Mon Sep 17 00:00:00 2001 From: jamiecobbett Date: Tue, 17 Feb 2026 12:43:40 +0000 Subject: [PATCH 2/2] Fix typo --- .github/workflows/{test-and-deplyo.yml => test-and-deploy.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/workflows/{test-and-deplyo.yml => test-and-deploy.yml} (100%) diff --git a/.github/workflows/test-and-deplyo.yml b/.github/workflows/test-and-deploy.yml similarity index 100% rename from .github/workflows/test-and-deplyo.yml rename to .github/workflows/test-and-deploy.yml