File tree Expand file tree Collapse file tree 2 files changed +41
-1
lines changed
Expand file tree Collapse file tree 2 files changed +41
-1
lines changed Original file line number Diff line number Diff line change 1818 echo "Purging jsDelivr cache for ${{ inputs.package }}"
1919 DELAY=${{ inputs.delay-ms }}
2020
21- find dist -type f | while read file; do
21+ find dist -type f ! -name "*.map" | while read file; do
2222 PURGE_URL="https://purge.jsdelivr.net/npm/${{ inputs.package }}/$file"
2323 echo "Purging: $PURGE_URL"
2424 curl --retry 3 --retry-delay 2 --fail -s "$PURGE_URL"
Original file line number Diff line number Diff line change 1+ name : 🧹 Purge jsDelivr Cache
2+
3+ on :
4+ workflow_dispatch :
5+ inputs :
6+ package :
7+ description :
' Package name and version (e.g. cloudinary-video-player, [email protected] , or cloudinary-video-player@edge)' 8+ required : true
9+ default : ' cloudinary-video-player'
10+ type : string
11+
12+ jobs :
13+ purge-cache :
14+ runs-on : ubuntu-latest
15+
16+ steps :
17+ - name : Checkout code
18+ uses : actions/checkout@v4
19+
20+ - name : Setup Node.js
21+ uses : actions/setup-node@v4
22+ with :
23+ node-version : ' 20.x'
24+
25+ - name : Install dependencies
26+ run : npm ci
27+
28+ - name : Build distribution files
29+ run : npm run build-all
30+
31+ - name : Purge jsDelivr Cache
32+ uses : ./.github/actions/purge-jsdelivr
33+ with :
34+ package : ${{ github.event.inputs.package }}
35+
36+ - name : Summary
37+ run : |
38+ echo "### ✅ jsDelivr Cache Purge Complete" >> $GITHUB_STEP_SUMMARY
39+ echo "Package: \`${{ github.event.inputs.package }}\`" >> $GITHUB_STEP_SUMMARY
40+ echo "Files purged from jsDelivr CDN cache (excluding .map files)" >> $GITHUB_STEP_SUMMARY
You can’t perform that action at this time.
0 commit comments