File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -40,17 +40,15 @@ jobs:
4040 registry-url : ' https://registry.npmjs.org'
4141
4242 - name : Extract version from package.json
43- id : package_version
44- run : echo "::set-output name=VERSION::$(node -p "require('./package.json').version")"
43+ run : echo "VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_ENV
4544
4645 - name : Check if version already published
4746 run : |
48- VERSION=${{ steps.package_version.outputs.VERSION }}
49- echo "Checking version: $VERSION"
50- NPM_VIEW_OUTPUT=$(npm view epsillajs@$VERSION)
47+ echo "Checking version: ${{ env.VERSION }}"
48+ NPM_VIEW_OUTPUT=$(npm view epsillajs@${{ env.VERSION }})
5149 echo "npm view output: $NPM_VIEW_OUTPUT"
5250 if [ -n "$NPM_VIEW_OUTPUT" ]; then
53- echo "Version $VERSION already exists on npm. Please update the version."
51+ echo "Version ${{ env. VERSION }} already exists on npm. Please update the version."
5452 exit 1
5553 fi
5654
5957 with :
6058 github_token : ${{ secrets.PAT_TOKEN }}
6159 tag_prefix : " v"
62- custom_tag : ${{ steps.package_version.outputs .VERSION }}
60+ custom_tag : ${{ env .VERSION }}
6361 dry_run : false
6462
6563 - name : Publish to npm
You can’t perform that action at this time.
0 commit comments