Skip to content

Commit c000908

Browse files
authored
Merge pull request #1230 from HarperFast/reenable-npm-tagging
Re-enable latest/next package tagging
2 parents f847836 + 74e16a7 commit c000908

1 file changed

Lines changed: 10 additions & 18 deletions

File tree

.github/workflows/publish-npm.yaml

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,12 @@ jobs:
3838
version: ${{ github.event.release.tag_name || inputs.tag_name }}
3939
- name: Set package tag
4040
id: package-tag
41-
# Once we have our first full, non-beta release, turn this back on:
42-
# run: |
43-
# if [[ "${{ steps.version-components.outputs.prerelease }}" == '' ]]; then
44-
# echo "packageTag=latest" >> "$GITHUB_OUTPUT"
45-
# else
46-
# echo "packageTag=next" >> "$GITHUB_OUTPUT"
47-
# fi
48-
# and get rid of this hard coded latest tagging:
4941
run: |
50-
echo "packageTag=latest" >> "$GITHUB_OUTPUT"
42+
if [[ "${{ steps.version-components.outputs.prerelease }}" == '' ]]; then
43+
echo "packageTag=latest" >> "$GITHUB_OUTPUT"
44+
else
45+
echo "packageTag=next" >> "$GITHUB_OUTPUT"
46+
fi
5147
- name: Publish package to NPM registry
5248
env:
5349
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
@@ -83,16 +79,12 @@ jobs:
8379
tar -czvf harperfast-harper-${{ steps.version-components.outputs.version }}.tgz package
8480
- name: Set package tag
8581
id: package-tag
86-
# Once we have our first full, non-beta release, turn this back on:
87-
# run: |
88-
# if [[ "${{ steps.version-components.outputs.prerelease }}" == '' ]]; then
89-
# echo "packageTag=latest" >> "$GITHUB_OUTPUT"
90-
# else
91-
# echo "packageTag=next" >> "$GITHUB_OUTPUT"
92-
# fi
93-
# and get rid of this hard coded latest tagging:
9482
run: |
95-
echo "packageTag=latest" >> "$GITHUB_OUTPUT"
83+
if [[ "${{ steps.version-components.outputs.prerelease }}" == '' ]]; then
84+
echo "packageTag=latest" >> "$GITHUB_OUTPUT"
85+
else
86+
echo "packageTag=next" >> "$GITHUB_OUTPUT"
87+
fi
9688
- name: Publish package to NPM registry
9789
env:
9890
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)