Help us improve
Share bugs, ideas, or general feedback.
From github-actions
Guide for using the GitHub CLI (gh) to manage GitHub Actions workflows in the crewchief repository.
npx claudepluginhub manifoldlogic/claude-code-plugins --plugin github-actionsHow this skill is triggered — by the user, by Claude, or both
Slash command
/github-actions:gh-cliThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Guide for using the GitHub CLI (gh) to manage GitHub Actions workflows in the crewchief repository.
Manages GitHub Actions workflows via gh CLI: check CI status, list/view/watch/rerun runs and logs.
Inspects GitHub Actions workflow runs using gh CLI: lists runs, checks status, analyzes logs, debugs failures, reruns jobs. Use for CI/CD troubleshooting.
Uses the gh CLI to manage GitHub issues, pull requests, view Actions workflow runs, and query the GitHub API. Helps debug CI failures and inspect PR status.
Share bugs, ideas, or general feedback.
Guide for using the GitHub CLI (gh) to manage GitHub Actions workflows in the crewchief repository.
Before using any gh commands, you MUST verify authentication:
gh auth status
If not authenticated, STOP and tell the user:
GitHub CLI is not authenticated. Please run
gh auth loginto authenticate before proceeding.
Do NOT attempt any gh commands until authentication is confirmed.
# List all workflows
gh workflow list
# List workflows with status
gh workflow list --all
# List recent workflow runs
gh run list
# List runs for a specific workflow
gh run list --workflow=ci.yml
# List failed runs only
gh run list --status=failure
# List runs for a specific branch
gh run list --branch=main
# View a specific run (by ID or URL)
gh run view <run-id>
# View with job details
gh run view <run-id> --verbose
# View failed jobs
gh run view <run-id> --log-failed
# Download all logs for a run
gh run download <run-id>
# Download specific artifact
gh run download <run-id> --name=<artifact-name>
# Trigger a workflow_dispatch workflow
gh workflow run <workflow-name>
# Trigger with inputs
gh workflow run <workflow-name> --field=environment=staging
# Rerun a failed workflow
gh run rerun <run-id>
# Rerun only failed jobs
gh run rerun <run-id> --failed
# Cancel a running workflow
gh run cancel <run-id>
Check authentication first:
gh auth status
List recent failures:
gh run list --status=failure --limit=5
View failed run logs:
gh run view <run-id> --log-failed
Download full logs for analysis:
gh run download <run-id> --dir=/tmp/workflow-logs
# List secrets (names only, not values)
gh secret list
# Set a secret
gh secret set SECRET_NAME
# List environment variables
gh variable list
--json flag for parsing output programmaticallyci.yml) not display name--limit to reduce output when listing many itemsCommon errors and solutions:
| Error | Solution |
|---|---|
gh: command not found | Install GitHub CLI: brew install gh or see https://cli.github.com/ |
not logged in | Run gh auth login |
HTTP 401 | Re-authenticate: gh auth login |
HTTP 403 | Check repository permissions |
HTTP 404 | Verify workflow/run exists, check repository name |
For programmatic use, add --json flag:
# List runs as JSON
gh run list --json status,conclusion,databaseId,workflowName
# View run as JSON
gh run view <run-id> --json jobs,status,conclusion