Skip to content

Commit 9f08e06

Browse files
committed
cd: gh action: add step to retrieve logs
1 parent 5cd2517 commit 9f08e06

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.github/workflows/release.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ on:
77

88
jobs:
99
release:
10+
name: "Release to NPM"
1011
runs-on: ubuntu-latest
1112
permissions:
1213
contents: write # Required to create the GitHub Release
@@ -51,6 +52,17 @@ jobs:
5152
npm publish --provenance --access public
5253
fi
5354
55+
- name: ⬆️ Upload NPM Debug Log on Failure
56+
if: failure()
57+
uses: actions/upload-artifact@v4
58+
with:
59+
# This name is what the file will be called when you download it
60+
name: npm-debug-log
61+
# Specify the exact path where npm saves its log on the runner
62+
path: /home/runner/.npm/_logs/*debug-*.log
63+
# Ignore the step if the file is not found (e.g., if the failure was not an npm error)
64+
if-no-files-found: ignore
65+
5466
- name: Create GitHub Release
5567
uses: softprops/action-gh-release@v2
5668
with:

0 commit comments

Comments
 (0)