FIX: Try a boolean argument for the CI instead
This commit is contained in:
committed by
Nicolás Hatcher Andrés
parent
0f6d311de2
commit
d3bc8b135c
11
.github/workflows/npm.yml
vendored
11
.github/workflows/npm.yml
vendored
@@ -12,11 +12,7 @@ permissions:
|
||||
publish:
|
||||
description: "Publish to npm"
|
||||
required: true
|
||||
type: choice
|
||||
options:
|
||||
- yes
|
||||
- no
|
||||
default: "no"
|
||||
type: boolean
|
||||
defaults:
|
||||
run:
|
||||
working-directory: ./bindings/nodejs
|
||||
@@ -437,10 +433,13 @@ jobs:
|
||||
shell: bash
|
||||
- name: Publish
|
||||
run: |
|
||||
cd bindings/nodejs
|
||||
npm config set provenance true
|
||||
if [ "${{ github.event.inputs.publish }}" = "yes" ]; then
|
||||
echo "${{ github.event.inputs.publish }}"
|
||||
if [ "${{ github.event.inputs.publish }}" = "true" ]; then
|
||||
echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> ~/.npmrc
|
||||
npm publish --access public
|
||||
echo "Published to npm"
|
||||
else
|
||||
echo "Not a release, skipping publish"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user