diff --git a/.github/workflows/cli.yml b/.github/workflows/cli.yml new file mode 100644 index 00000000..81fb088d --- /dev/null +++ b/.github/workflows/cli.yml @@ -0,0 +1,20 @@ +name: Publish CLI Package to npm +on: + push: + tags: + # This is a glob pattern not a regex + - 'cli/v[0-9]+.[0-9]+.[0-9]+' +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Setup + uses: ./tooling/github/setup + + - run: pnpm publish --access public --no-git-checks + working-directory: apps/cli + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_ACCESS_TOKEN }} + diff --git a/tooling/github/setup/action.yml b/tooling/github/setup/action.yml index 9a8ff513..c0b3d85c 100644 --- a/tooling/github/setup/action.yml +++ b/tooling/github/setup/action.yml @@ -9,6 +9,7 @@ runs: with: node-version: 21 cache: "pnpm" + registry-url: https://registry.npmjs.org - shell: bash run: pnpm add -g turbo