Github Actions Delete All Workflow Runs


Today I ran a bunch of actions, but I wanted to clean up all the runs that I used to get it setup so that I had a good clean history to refer back to later.

I found this post

gh api \
    repos/waylonwalker/hatch-version-action-example/actions/runs | \
    jq '.workflow_runs[].id' | \
    xargs -n1 -I % gh api repos/waylonwalker/hatch-version-action-example/actions/runs/% -X DELETE