diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 86f0c28..2619ff1 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -24,20 +24,23 @@ jobs: - name: Get package.json version id: get-version run: | - echo "version=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT + echo "VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT - name: Get latest npm version id: get-npm-version run: | - echo "latest=$(npm show convconv version)" >> $GITHUB_OUTPUT + echo "LATEST=$(npm show convconv version)" >> $GITHUB_OUTPUT - name: Compare versions id: compare-versions run: | - echo "should-publish=$([[ $VERSION > $LATEST ]] && echo -n 'true' || echo -n 'false')" >> $GITHUB_OUTPUT + echo "$LATEST" + echo "$VERSION" + echo "should_publish=$([[ $VERSION > $LATEST ]] && echo -n 'true' || echo -n 'false')" + echo "should_publish=$([[ $VERSION > $LATEST ]] && echo -n 'true' || echo -n 'false')" >> $GITHUB_OUTPUT - name: Publish to npm - if: steps.compare-versions.outputs.should-publish == 'true' + if: steps.compare-versions.outputs.should_publish == 'true' env: NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} run: |