Workflow: purge CDN after a new release

This commit is contained in:
loyalsoldier 2021-08-28 19:34:40 +08:00
parent 012a6308ee
commit 1971d7a499
No known key found for this signature in database
GPG Key ID: 23829BBC1ACF2C90

View File

@ -210,3 +210,10 @@ jobs:
git commit -m "${{ env.RELEASE_NAME }}"
git remote add origin "https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}"
git push -f -u origin release
- name: Purge jsdelivr CDN
run: |
cd publish || exit 1
for file in $(ls); do
curl -i "https://purge.jsdelivr.net/gh/${{ github.repository }}@release/${file}"
done