Skip to content

Enable pnpm in CI using corepack #17

Enable pnpm in CI using corepack

Enable pnpm in CI using corepack #17

Workflow file for this run

name: Publish on Version Change
on:
push:
branches:
- main
paths:
- 'package.json'
- 'packages/**/package.json'
workflow_dispatch:
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: write
packages: write
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
registry-url: 'https://registry.npmjs.org/'
- name: Install dependencies
<<<<<<< Updated upstream

Check failure on line 32 in .github/workflows/release.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/release.yml

Invalid workflow file

You have an error in your yaml syntax on line 32
run: pnpm ci
=======
run: |
corepack enable
corepack prepare pnpm@latest --activate
pnpm ci
>>>>>>> Stashed changes
- name: Build project
run: npx turbo run build
# pnpm will publish all packages in the monorepo
# --provenance for comprehensive metadata about the build process,
# enhancing the security and traceability of artifacts
- name: Publish adaptate to npm
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_USER_TOKEN }}
run: pnpm publish --recursive --provenance --access public
# - name: Publish @adaptate/core to GitHub Packages
# working-directory: packages/core
# env:
# NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# run: npm publish --registry=https://npm.pkg.github.com/