Skip to content

Commit 3bacf56

Browse files
committed
ci(release): always create GitHub Release; continue-on-error for npm publish; run notes on failure
1 parent a24c998 commit 3bacf56

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

.github/workflows/release-on-tag.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ jobs:
3737
- name: Test
3838
run: npm test --if-present
3939
- name: Publish to npm
40+
continue-on-error: true
4041
run: |
4142
pkg_private=$(node -e "try{console.log(require('./package.json').private===true?'true':'false')}catch(e){console.log('false')}")
4243
if [ "$pkg_private" = "true" ]; then
@@ -49,12 +50,14 @@ jobs:
4950
- name: Read package version
5051
id: pkg
5152
shell: bash
53+
if: always()
5254
run: |
5355
VERSION=$(node -p "require('./package.json').version")
5456
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
5557
- name: Generate release notes from CHANGELOG.md
5658
id: notes
5759
shell: bash
60+
if: always()
5861
run: |
5962
if [ -f CHANGELOG.md ]; then
6063
export VERSION="${{ steps.pkg.outputs.version }}"
@@ -76,6 +79,7 @@ jobs:
7679
echo "EOF" >> $GITHUB_OUTPUT
7780
fi
7881
- name: Create/Update GitHub Release
82+
if: always()
7983
uses: ncipollo/release-action@v1
8084
with:
8185
token: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)