To delete all your workflow runs, use this workflow file .github/workflows/clean.yml
in your root directory and run it via workflow_dispatch
.
Created
August 22, 2021 07:46
-
-
Save jainamoswal/77d228bb8d8d6c512a960ec8e95eaec5 to your computer and use it in GitHub Desktop.
This file contains 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
name: 🗑 Delete workflow runs 🗑 | |
on: | |
workflow_dispatch: | |
inputs: | |
days: | |
description: 'Number of days.' | |
required: true | |
default: "5" | |
minimum_runs: | |
description: 'Minimum runs to keep.' | |
required: true | |
default: "1" | |
jobs: | |
delete_runs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Delete workflow runs | |
uses: Mattraks/delete-workflow-runs@main | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
repository: ${{ github.repository }} | |
retain_days: ${{ github.event.inputs.days }} | |
keep_minimum_runs: ${{ github.event.inputs.minimum_runs }} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment