Skip to content

v0.4.0-rc.3

v0.4.0-rc.3 #63

Workflow file for this run

name: Release NPM Package
on:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: "0"
token: ${{ secrets.ORY_BOT_PAT }}
- uses: actions/setup-node@v4
with:
node-version: "20"
- run: npm ci
- run: npm run build:clean
- run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN_AENEASR }}" > ~/.npmrc
- run: make format
- run: |
git config --global user.email "[email protected]"
git config --global user.name "ory-bot"
git add -A
- uses: actions/github-script@v7
id: compute-dist-tag
with:
script: |
const isPrerelease = context.payload.release.prerelease;
return isPrerelease ? 'next' : 'latest';
result-encoding: string
- run: |
npx nx release version ${{ github.event.release.tag_name }} --git-commit=false --stage-changes=false
npx nx release publish --specifier=${{ github.event.release.tag_name }} --tag="${{ steps.compute-dist-tag.outputs.result }}" --git-commit-message 'chore(release): bump version to ${{ github.event.release.tag_name }}' --git-tag=false
# TODO(jonas): commit the result to the main branch, if it's not a prerelease