Created
July 14, 2021 15:02
-
-
Save saade/666493b9cc05ab28de5f7766e36157ed to your computer and use it in GitHub Desktop.
Delete all workflow runs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
user=GH_USERNAME repo=REPO_NAME; gh api repos/$user/$repo/actions/runs \ | |
--paginate -q '.workflow_runs[] | select(.head_branch != "master") | "\(.id)"' | \ | |
xargs -n1 -I % gh api repos/$user/$repo/actions/runs/% -X DELETE |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment