Merge pull request #654 from pmndrs/dev #96
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: CD | |
on: | |
workflow_dispatch: | |
push: | |
tags: | |
- "*" | |
jobs: | |
deploy: | |
name: Deploy | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git checkout | |
uses: actions/checkout@v4 | |
- name: Install PNPM | |
uses: pnpm/action-setup@v4 | |
with: | |
version: 9 | |
- name: Install Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
cache: "pnpm" | |
- name: Install dependencies and test | |
run: pnpm install-test --frozen-lockfile | |
- name: Publish | |
id: publish | |
uses: JS-DevTools/npm-publish@v3 | |
with: | |
token: ${{ secrets.NPM_TOKEN }} | |
- if: ${{ steps.publish.outputs.type }} | |
run: | | |
echo "Published version: ${{ steps.publish.outputs.version }}" | |
- name: Deploy | |
run: pnpm run deploy | |
- uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
branch: gh-pages | |
folder: public | |
target-folder: public | |
single-commit: true |