[to remove] publish missing version #216
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| on: | |
| push: | |
| permissions: | |
| id-token: write # Required for OIDC. See https://docs.npmjs.com/trusted-publishers#step-2-configure-your-cicd-workflow | |
| contents: read | |
| jobs: | |
| # changelog: | |
| # uses: "./.github/workflows/changelog.yml" | |
| # test: | |
| # uses: "OpenTermsArchive/engine/.github/workflows/test.yml@main" | |
| release: | |
| # needs: [ changelog, test ] | |
| # if: github.event.pull_request.merged == true && needs.changelog.outputs.release-type != 'no-release' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| ref: main | |
| token: ${{ secrets.RELEASE_BOT_GITHUB_TOKEN }} | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '24' | |
| registry-url: 'https://registry.npmjs.org' | |
| - name: Configure Git author | |
| run: | | |
| git config --global user.name "Open Terms Archive Release Bot" | |
| git config --global user.email "[email protected]" | |
| - name: Update changelog for release | |
| id: release-changelog | |
| uses: OpenTermsArchive/changelog-action/[email protected] | |
| - name: Bump package version | |
| run: npm --no-git-tag-version version 10.2.0 | |
| # - name: Commit CHANGELOG.md and package.json changes and create tag | |
| # run: | | |
| # git add "package.json" | |
| # git add "package-lock.json" | |
| # git add "CHANGELOG.md" | |
| # git commit -m "Release v${{ steps.release-changelog.outputs.version }}" | |
| # git tag v${{ steps.release-changelog.outputs.version }} | |
| # Publish to NPM first, before pushing to repository | |
| # If this fails, no changes are pushed to the repository, ensuring consistency | |
| - name: Publish to NPM public repository | |
| run: npm publish --provenance | |
| # Only push to repository after successful NPM publish | |
| - name: Push changes to repository | |
| run: git push --tags | |
| - name: Create GitHub release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| tag_name: v10.2.0 | |
| body: | | |
| ## 10.2.0 - 2026-01-08 | |
| _Full changeset and discussions: [#1219](https://github.com/OpenTermsArchive/engine/pull/1219)._ | |
| > Development of this release was supported by [Reset Tech](https://www.reset.tech). | |
| ### Changed | |
| - Add `Advertising Content Policy` terms type, introduced in [`[email protected]`](https://github.com/OpenTermsArchive/terms-types/blob/main/CHANGELOG.md#220---2025-12-30) | |
| token: ${{ secrets.RELEASE_BOT_GITHUB_TOKEN }} | |
| - name: Trigger documentation deploy | |
| uses: peter-evans/repository-dispatch@v2 | |
| with: | |
| token: ${{ secrets.TRIGGER_DOCS_DEPLOY_TOKEN }} | |
| event-type: engine-release | |
| repository: OpenTermsArchive/docs | |
| client-payload: '{"version": "v10.2.0"}' | |
| # clean_changelog: | |
| # if: github.event.pull_request.merged == true && needs.changelog.outputs.release-type == 'no-release' | |
| # needs: [ changelog ] | |
| # runs-on: ubuntu-latest | |
| # steps: | |
| # - uses: actions/checkout@v4 | |
| # with: | |
| # ref: main | |
| # token: ${{ secrets.RELEASE_BOT_GITHUB_TOKEN }} | |
| # - name: Configure Git author | |
| # run: | | |
| # git config --global user.name "Open Terms Archive Release Bot" | |
| # git config --global user.email "[email protected]" | |
| # - name: Update changelog for release | |
| # uses: OpenTermsArchive/changelog-action/[email protected] | |
| # - name: Save changelog | |
| # run: | | |
| # git commit -m "Clean changelog" CHANGELOG.md | |
| # git push origin main |