diff --git a/.github/actions/npmInstallWithRetries/action.yml b/.github/actions/npmInstallWithRetries/action.yml index 822c729..30c64cf 100644 --- a/.github/actions/npmInstallWithRetries/action.yml +++ b/.github/actions/npmInstallWithRetries/action.yml @@ -7,7 +7,10 @@ inputs: runs: using: composite steps: - - name: npm install + - name: timeout config + run: npm config set fetch-timeout 600000 + shell: bash + - name: npm ci uses: salesforcecli/github-workflows/.github/actions/retry@main with: - command: npm install --timeout 600000 ${{ inputs.ignore-scripts == 'true' && '--ignore-scripts' || '' }} + command: npm ci --no-audit --no-fund ${{ inputs.ignore-scripts == 'true' && '--ignore-scripts' || '' }} diff --git a/.github/workflows/npmPublish.yml b/.github/workflows/npmPublish.yml index 31943ba..5b1f5a4 100644 --- a/.github/workflows/npmPublish.yml +++ b/.github/workflows/npmPublish.yml @@ -61,6 +61,12 @@ on: required: false default: true type: boolean + packagePath: + description: relative path to the package to publish, should start with a ".". Defaults to the root of the repository. Useful for monorepos. + required: false + type: string + default: . + jobs: check-publish: outputs: @@ -96,6 +102,7 @@ jobs: fi env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + working-directory: ${{ inputs.packagePath }} - run: echo "[INFO] Is package published:\ $STEPS_IS_PUBLISHED_PUBLISHED" env: @@ -279,6 +286,7 @@ jobs: ${{ inputs.dryrun && '--dryrun' || '' }} \ ${{ inputs.prerelease && format('--prerelease {0}', github.ref_name) || '' }} \ ${{ inputs.sign && '--sign' || '' }} + working-directory: ${{ inputs.packagePath }} env: NPM_TOKEN: ${{secrets.NPM_TOKEN}} AWS_ACCESS_KEY_ID: ${{secrets.AWS_ACCESS_KEY_ID}}