Gh fix ci

From PramodDutta/qaskills · View interactive version

Gh fix ci is an AI agent skill from the GitHub repository PramodDutta/qaskills. Debug and fix failing GitHub PR checks by inspecting GitHub Actions logs, summarizing failure context, drafting fix plans, and implementing fixes after approval.

How to use this skill

Skill file

GitHub CI Fix Debugging

Use gh CLI to locate failing PR checks, fetch GitHub Actions logs for actionable failures, summarize the failure, propose a fix plan, and implement after explicit approval.

Prerequisites

Authenticate with the GitHub CLI:

gh auth login  # Ensure repo + workflow scopes
gh auth status  # Verify authentication

Workflow

1. Verify Authentication

gh auth status

If unauthenticated, ask the user to run gh auth login with repo + workflow scopes.

2. Resolve the PR

# Current branch PR
gh pr view --json number,url

# Or use a specific PR number
gh pr checks <pr-number>

3. Inspect Failing Checks

# List all PR checks with status
gh pr checks <pr> --json name,state,bucket,link,startedAt,completedAt,workflow

# For each failing check, get the run details
gh run view <run_id> --json name,workflowName,conclusion,status,url

# Fetch the logs
gh run view <run_id> --log

4. Scope Non-GitHub Actions Checks

5. Summarize Failures

For each failing check, provide:

6. Create a Fix Plan

Draft a concise plan including:

7. Implement After Approval

8. Recheck Status

# After fixes, verify checks pass
gh pr checks <pr>

Common CI Failure Patterns

Test Failures

Build Failures

Lint/Format Failures

Timeout Issues

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.