chore: release v0.1.106 #45
Workflow file for this run
This file contains 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: | |
workflow_dispatch: | |
push: | |
tags: | |
- 'v*' | |
branches: | |
# for debugging purposes | |
- 'debug-*' | |
defaults: | |
run: | |
shell: bash | |
env: | |
# Enable debug logging for actions | |
ACTIONS_RUNNER_DEBUG: true | |
jobs: | |
changelog: | |
name: 'Generate Changelog' | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Checkout' | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: 'Generate Changelog' | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: npx changelogithub --no-group | |
continue-on-error: true | |
publish-npm: | |
name: 'NPM Registry' | |
needs: [changelog] | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Checkout' | |
uses: actions/checkout@v3 | |
- name: 'Setup pnpm' | |
uses: pnpm/[email protected] | |
with: | |
version: 'latest' | |
- name: 'Setup Node.js' | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 'lts/*' | |
cache: 'pnpm' | |
registry-url: 'https://registry.npmjs.org' | |
- name: 'Install Dependencies' | |
run: pnpm install --frozen-lockfile | |
- name: 'Build' | |
env: | |
NODE_ENV: 'production' | |
run: pnpm build | |
- name: 'Publish' | |
env: | |
NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
run: | | |
pnpm publish --access='public' --registry='https://registry.npmjs.org' --no-git-checks | |
publish-gpr: | |
name: 'GitHub Package Registry' | |
needs: [changelog] | |
permissions: write-all | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Checkout' | |
uses: actions/checkout@v3 | |
- name: 'Setup pnpm' | |
uses: pnpm/[email protected] | |
with: | |
version: 'latest' | |
- name: 'Setup Node.js' | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 'lts/*' | |
cache: 'pnpm' | |
registry-url: 'https://npm.pkg.github.com' | |
- name: 'Install Dependencies' | |
run: pnpm install --frozen-lockfile | |
- name: 'Build' | |
env: | |
NODE_ENV: 'production' | |
run: pnpm build | |
- name: 'Update ~/.npmrc' | |
run: | | |
echo "//npm.pkg.github.com:_authToken=${{ secrets.GITHUB_TOKEN }}" >> .npmrc | |
- name: 'Publish' | |
env: | |
NPM_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
pnpm publish --access='public' --registry='https://npm.pkg.github.com' --no-git-checks |