Skip to content

Publish

Publish #88

Workflow file for this run

name: Publish
on:
workflow_dispatch: {}
jobs:
publish:
name: Publish
runs-on: ubuntu-20.04
steps:
- name: Checkout Repo
uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 18
cache: 'pnpm'
- name: Install Dependencies
run: pnpm install --frozen-lockfile
# - name: E2E Tests
# working-directory: packages/e2e
# run: pnpm test
- name: Create Changelog
id: changelog
uses: TriPSs/conventional-changelog-action@v3
with:
github-token: ${{ secrets.github_token }}
output-file: "false"
version-file: ./packages/vite-plugin-web-extension/package.json
- name: Publish to NPM
if: ${{ steps.changelog.outputs.skipped == 'false' }}
working-directory: packages/vite-plugin-web-extension
run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN }}" > ~/.npmrc
pnpm publish
- name: Create Release
uses: actions/create-release@v1
if: ${{ steps.changelog.outputs.skipped == 'false' }}
env:
GITHUB_TOKEN: ${{ secrets.github_token }}
with:
tag_name: ${{ steps.changelog.outputs.tag }}
release_name: ${{ steps.changelog.outputs.tag }}
body: ${{ steps.changelog.outputs.clean_changelog }}