A CLI tool to manage GitHub Actions workflows and jobs across multiple repositories.
- Authenticate with a GitHub token
- List workflow runs filtered by branch or commit
- Display logs/status in a hierarchical format
- Restart failed jobs by job-id or group success
To use this tool, you must provide a GitHub personal access token (PAT) with appropriate permissions. The required scopes are:
- repo: Full control of private repositories (for accessing and managing workflows in private repos)
- workflow: Update GitHub Action workflows
python gh_action_manager.py --repository owner/repo --token <token> [options]--branch <branch>: Filter by branch--commit <sha>: Filter by commit SHA--exclude-success: Exclude jobs with status 'success' from output and skip workflow runs where all jobs succeeded--restart-majority: Restart all failed jobs in a workflow run if the percentage of successful jobs meets the threshold--restart-threshold <percent>: Threshold percentage of successful jobs to trigger restart (default: 75)--restart <job-id>: Restart job by job-id (future/optional)--restart-group: Restart failed jobs by group success (future/optional)
Show only failed jobs and restart failed jobs if at least 80% succeeded:
python gh_action_manager.py --repository grindsa/acme2certifier --token <token> --exclude-success --restart-majority --restart-threshold 80- Python 3.8+
- requests
- rich (optional, for pretty output)
Install dependencies:
pip install -r requirements.txt