debug: log Gitea Commit syntax

This commit is contained in:
gitea-analytics-bot
2026-01-21 21:41:06 -05:00
parent 2cfb935aee
commit 79dc7b6484

View File

@@ -22,11 +22,16 @@ jobs:
- name: Fetch Commit Velocity
run: |
SINCE_DATE="2026-01-01T00:00:00Z"
URL="http://gitea-http:3000/api/v1/repos/${{ github.repository }}/commits?since=${SINCE_DATE}&limit=5000"
URL="http://gitea-http:3000/api/v1/repos/${{ github.repository }}/commits?since=${SINCE_DATE}&limit=1000"
RAW_COUNT=$(wget -qO- --header="Authorization: token ${{ secrets.GITHUB_TOKEN }}" "$URL" | grep -c "\"sha\":" || echo 0)
wget -qO response.json --header="Authorization: token ${{ secrets.GITHUB_TOKEN }}" "$URL"
echo "Final count: $RAW_COUNT"
echo "API Response Preview:"
head -n 10 response.json
RAW_COUNT=$(grep -c "\"url\":" response.json || echo 0)
echo "Final count detected: $RAW_COUNT"
echo "COMMIT_VELOCITY=$RAW_COUNT" >> $GITHUB_ENV
- name: Update README