Watch
1
0
Fork
You've already forked RedFlag
0

nightly: use target_commitish for previous SHA detection instead of body parsing

This commit is contained in:
Fimeg 2026-06-29 16:04:52 -04:00
commit 0d260f4903

View file

@ -42,10 +42,11 @@ jobs:
PREV=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
"$API/repos/${GITHUB_REPOSITORY}/releases/tags/nightly" \
| python3 -c "
import json,sys,re
import json,sys
try:
m = re.search(r'commit: ([0-9a-f]{40})', json.load(sys.stdin).get('body',''))
print(m.group(1) if m else '')
r = json.load(sys.stdin)
sha = r.get('target_commitish','')
print(sha if len(sha) == 40 else '')
except Exception:
print('')")
if [ "$PREV" = "$SHA" ]; then