Fix badge cache purge by using GitHub API instead of scraping page HTML
All checks were successful
CI / shellcheck (push) Successful in 16s
All checks were successful
CI / shellcheck (push) Successful in 16s
GitHub's repository page is JS-rendered, so curl gets a skeleton without README images. Use the rendered README API endpoint instead, which returns actual HTML including camo-proxied image URLs. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
28170d02d0
commit
57d2c38d3c
1 changed files with 3 additions and 1 deletions
|
|
@ -18,7 +18,9 @@ jobs:
|
|||
run: shellcheck systab
|
||||
- name: Purge GitHub mirror badge cache
|
||||
run: |
|
||||
curl -sL https://github.com/opennomad/systab \
|
||||
curl -sL \
|
||||
-H "Accept: application/vnd.github.html+json" \
|
||||
"https://api.github.com/repos/opennomad/systab/readme" \
|
||||
| grep -oP 'https://camo\.githubusercontent\.com/[^"]+' \
|
||||
| sort -u \
|
||||
| xargs -r -I{} curl -sX PURGE '{}' || true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue