From 449e9b68a0b29252b03a02ac31ccfb63091a0af9 Mon Sep 17 00:00:00 2001 From: Camden Narzt Date: Fri, 2 Aug 2024 10:58:22 -0600 Subject: [PATCH] fixup working dirs in npm workflow --- .github/workflows/npm.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/npm.yml b/.github/workflows/npm.yml index 1058e86..daecbbb 100644 --- a/.github/workflows/npm.yml +++ b/.github/workflows/npm.yml @@ -26,21 +26,28 @@ jobs: run: sudo make install_dylib working-directory: getargv - uses: actions/checkout@v4 + with: + path: getargv.js - run: sed -e 's/@camjn/@getargv/' -i '' package.json + working-directory: getargv.js - uses: actions/setup-node@v4 with: node-version: latest scope: '@getargv' registry-url: https://npm.pkg.github.com/ - run: npm ci + working-directory: getargv.js - run: | echo registry=https://npm.pkg.github.com/ > .npmrc echo always-auth=true >> .npmrc echo //npm.pkg.github.com/:_authToken=${{ github.token }} >> .npmrc + working-directory: getargv.js - run: npm publish + working-directory: getargv.js env: NODE_AUTH_TOKEN: ${{ github.token }} - run: npm config list + working-directory: getargv.js if: ${{ failure() }} publish-npm: @@ -60,11 +67,15 @@ jobs: run: sudo make install_dylib working-directory: getargv - uses: actions/checkout@v4 + with: + path: getargv.js - uses: actions/setup-node@v4 with: node-version: latest registry-url: https://registry.npmjs.org/ - run: npm ci + working-directory: getargv.js - run: npm publish --provenance --access public + working-directory: getargv.js env: NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}