9.0.0-beta.0 #1
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: Publish packages | |
on: | |
push: | |
tags: | |
- v* | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout 🏷️ | |
uses: actions/checkout@v3 | |
- name: Match tag to package version 🧐 | |
id: packageVersion | |
uses: geritol/[email protected] | |
with: | |
TAG_PREFIX: v | |
- name: Set up Node 🕹️ | |
uses: actions/setup-node@v3 | |
with: | |
node-version-file: 'package.json' | |
registry-url: 'https://registry.npmjs.org' | |
- name: Install pnpm ⚙️ | |
uses: pnpm/action-setup@v2 | |
with: | |
version: 8.x | |
- name: Restore cache 📌 | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/setup-pnpm/node_modules/.bin/store | |
~/.cache/Cypress | |
key: cache-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }} | |
restore-keys: | | |
${{ runner.os }}- | |
- name: Install dependencies ⚙️ | |
run: pnpm install --frozen-lockfile | |
- name: Build packages 📦 | |
run: pnpm packages | |
- name: Set @h5web/lib version 📌 | |
uses: reedyuk/[email protected] | |
with: | |
version: ${{ steps.packageVersion.outputs.PACKAGE_VERSION }} | |
package: 'packages/lib' | |
- name: Set @h5web/app version 📌 | |
uses: reedyuk/[email protected] | |
with: | |
version: ${{ steps.packageVersion.outputs.PACKAGE_VERSION }} | |
package: 'packages/app' | |
- name: Set @h5web/h5wasm version 📌 | |
uses: reedyuk/[email protected] | |
with: | |
version: ${{ steps.packageVersion.outputs.PACKAGE_VERSION }} | |
package: 'packages/h5wasm' | |
- name: Publish @h5web/lib 🥳 | |
run: cd packages/lib && pnpm publish --access public --no-git-checks --tag $NPM_TAG | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
NPM_TAG: "${{ contains(steps.packageVersion.outputs.PACKAGE_VERSION, 'beta') && 'next' || 'latest' }}" | |
- name: Publish @h5web/app 🥳 | |
run: cd packages/app && pnpm publish --access public --no-git-checks --tag $NPM_TAG | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
NPM_TAG: "${{ contains(steps.packageVersion.outputs.PACKAGE_VERSION, 'beta') && 'next' || 'latest' }}" | |
- name: Publish @h5web/h5wasm 🥳 | |
run: cd packages/h5wasm && pnpm publish --access public --no-git-checks --tag $NPM_TAG | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
NPM_TAG: "${{ contains(steps.packageVersion.outputs.PACKAGE_VERSION, 'beta') && 'next' || 'latest' }}" |