From 7bcc276a6a740e8cacd750289b6898147dc37c18 Mon Sep 17 00:00:00 2001 From: alexisnsns Date: Wed, 20 Dec 2023 15:24:29 -0500 Subject: [PATCH] fix yml script monorepo --- .github/workflows/npm-publish.yml | 41 +++++++++++++------------------ 1 file changed, 17 insertions(+), 24 deletions(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index eec14bc..636e931 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -8,31 +8,24 @@ jobs: publish-npm: runs-on: ubuntu-latest steps: - - name: Check out code - uses: actions/checkout@v3 + - name: Check out code + uses: actions/checkout@v3 - - name: Set up Node.js - uses: actions/setup-node@v3 - with: - node-version: "16" - registry-url: "https://registry.npmjs.org" + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: "16" + registry-url: "https://registry.npmjs.org" - - name: Install dependencies for JS SDK - run: npm install - working-directory: packages/sdk/js + - name: Install dependencies + run: npm install - - name: Publish JS SDK to NPM - run: npm publish - working-directory: packages/sdk/js - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + - name: Publish JS SDK to NPM + run: npm publish --workspace=sdk/js + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} - - name: Install dependencies for React components - run: npm install - working-directory: packages/ui/lib - - - name: Publish React components to NPM - run: npm publish - working-directory: packages/ui/lib - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + - name: Publish React components to NPM + run: npm publish --workspace=ui/lib + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}