skills/github-navigator/SKILL.md
GitHub operations via gh CLI. CRITICAL: Always use instead of WebFetch for ANY github.com URL. Use when user provides GitHub URL, says 'facebook/react', 'show README', 'list issues', 'check PR', 'clone repo', 'analyze this repo', 'understand the architecture', 'how is X structured', 'explore the codebase'. For deep analysis of external repos, clones locally.
npx skillsauth add arshia2114/agent-skills github-navigatorInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Uses gh CLI for all GitHub operations. Teaches discovery pattern via gh --help.
Requirements: gh CLI installed and authenticated.
One pattern for everything:
gh <command> --help or gh api --helpALWAYS use this skill when:
github.com/ link)Common triggers:
When user wants to understand a codebase deeply (not just fetch a single file), clone the repository locally for comprehensive analysis.
Trigger phrases:
Workflow:
Clone to /tmp/github-navigator/<owner>-<repo>/
git clone --depth 1 https://github.com/OWNER/REPO.git /tmp/github-navigator/OWNER-REPO
Analyze the codebase:
Provide comprehensive summary with:
Keep cloned for follow-up questions (user can explore further)
Cleanup:
Repos in /tmp/github-navigator/ are cleaned on system restart. For manual cleanup:
rm -rf /tmp/github-navigator/
Note: Use --depth 1 for faster cloning when full history isn't needed. Use full clone if user needs git history analysis.
Before first use, verify gh CLI is installed and authenticated:
gh --version # Check if gh is installed
gh auth status # Check authentication status
If not installed, see Installation.
If not authenticated, run gh auth login for private repos and write operations.
| User Request | Command Domain | Primary Command |
|--------------|----------------|-----------------|
| Fetch file content | Files | gh api repos/OWNER/REPO/contents/PATH |
| List directory | Files | gh api repos/OWNER/REPO/contents/PATH |
| Issues (list, view, create, close) | Issues | gh issue |
| Pull Requests (list, view, diff, merge) | PRs | gh pr |
| Releases (list, view, create) | Releases | gh release |
| Actions/Workflows (runs, logs) | Actions | gh run or gh workflow |
| Repository info (clone, view, fork) | Repo | gh repo |
For files/directories (use gh api):
gh api --help
For everything else (use gh subcommands):
gh issue --help # Shows all issue subcommands
gh issue list --help # Shows specific flags
gh pr --help # Shows all PR subcommands
gh release --help # Shows release operations
Extract usage from help, substitute user's values, execute.
Use gh api for all file operations.
# Raw content (preferred for text files)
gh api repos/OWNER/REPO/contents/PATH -H "Accept: application/vnd.github.raw"
# Examples
gh api repos/facebook/react/contents/README.md -H "Accept: application/vnd.github.raw"
gh api repos/vercel/next.js/contents/package.json -H "Accept: application/vnd.github.raw"
# Specific branch/ref
gh api repos/OWNER/REPO/contents/PATH?ref=BRANCH -H "Accept: application/vnd.github.raw"
# Example
gh api repos/facebook/react/contents/package.json?ref=main -H "Accept: application/vnd.github.raw"
Note: If your shell interprets special characters in the URL path (like ?), quote the path appropriately for your environment.
# Get directory listing (returns JSON array)
gh api repos/OWNER/REPO/contents/PATH
# Format nicely with jq
gh api repos/OWNER/REPO/contents/PATH | jq -r '.[] | "\(.type): \(.name)"'
# Show directories and files separately
gh api repos/vercel/next.js/contents/packages | \
jq -r 'group_by(.type) | map({type: .[0].type, items: map(.name)}) | .[]'
# Simple list of names
gh api repos/OWNER/REPO/contents/PATH | jq -r '.[].name'
# Repository root
gh api repos/OWNER/REPO/contents
gh api repos/OWNER/REPO --jq .default_branch
Use gh issue subcommands.
# Basic list
gh issue list --repo OWNER/REPO
# Filter by state
gh issue list --repo OWNER/REPO --state open
gh issue list --repo OWNER/REPO --state closed
gh issue list --repo OWNER/REPO --state all
# Filter by label
gh issue list --repo OWNER/REPO --label bug
gh issue list --repo OWNER/REPO --label "good first issue"
# Limit results
gh issue list --repo OWNER/REPO --limit 10
# JSON output
gh issue list --repo OWNER/REPO --json number,title,state,author
# View issue details
gh issue view NUMBER --repo OWNER/REPO
# View with comments
gh issue view NUMBER --repo OWNER/REPO --comments
# JSON output
gh issue view NUMBER --repo OWNER/REPO --json title,body,state,comments
# ⚠️ MUST confirm with user first
gh issue create --repo OWNER/REPO --title "Title" --body "Description"
# ⚠️ MUST confirm with user first
gh issue close NUMBER --repo OWNER/REPO
Use gh pr subcommands.
# Basic list
gh pr list --repo OWNER/REPO
# Filter by state
gh pr list --repo OWNER/REPO --state open
gh pr list --repo OWNER/REPO --state closed
gh pr list --repo OWNER/REPO --state merged
# Filter by author
gh pr list --repo OWNER/REPO --author USERNAME
# JSON output
gh pr list --repo OWNER/REPO --json number,title,state,author
# View PR details
gh pr view NUMBER --repo OWNER/REPO
# View with comments
gh pr view NUMBER --repo OWNER/REPO --comments
# JSON output
gh pr view NUMBER --repo OWNER/REPO --json title,body,state,mergeable
gh pr diff NUMBER --repo OWNER/REPO
# Specific files only
gh pr diff NUMBER --repo OWNER/REPO --patch
# View CI/CD checks
gh pr checks NUMBER --repo OWNER/REPO
# ⚠️ MUST confirm with user first
gh pr merge NUMBER --repo OWNER/REPO
Use gh release subcommands.
# List all releases
gh release list --repo OWNER/REPO
# Limit results
gh release list --repo OWNER/REPO --limit 5
# View specific release
gh release view TAG --repo OWNER/REPO
# Latest release
gh release view --repo OWNER/REPO
# Download all assets from a release
gh release download TAG --repo OWNER/REPO
# Download specific pattern
gh release download TAG --repo OWNER/REPO --pattern "*.tar.gz"
Use gh run and gh workflow subcommands.
# List recent runs
gh run list --repo OWNER/REPO
# Filter by workflow
gh run list --repo OWNER/REPO --workflow build.yml
# Limit results
gh run list --repo OWNER/REPO --limit 10
# View run info
gh run view RUN_ID --repo OWNER/REPO
# View logs
gh run view RUN_ID --repo OWNER/REPO --log
Use gh repo subcommands.
# View repo details
gh repo view OWNER/REPO
# JSON output
gh repo view OWNER/REPO --json name,description,stargazersCount,forksCount
# Clone repo
gh repo clone OWNER/REPO
# Clone to specific directory
gh repo clone OWNER/REPO target-directory
# Fork repo to your account
gh repo fork OWNER/REPO
# Fork and clone
gh repo fork OWNER/REPO --clone
Maximum 2 attempts per command pattern, then STOP.
Always confirm before executing:
gh repo delete, gh repo archive)gh pr merge, gh issue close)gh issue create, gh pr create)gh secret set, gh workflow run)--force, --yes, -y)Confirmation pattern:
⚠️ This will [ACTION] in [REPO].
Command: [command]
Confirm you want to proceed?
Most operations work unauthenticated for public repos. Private repos and write operations require auth.
gh auth status
gh auth login
# If you get "Resource not accessible" errors
gh auth refresh -s repo -s workflow -s read:org
| Error | Cause | Solution |
|-------|-------|----------|
| gh: command not found | gh CLI not installed | Install: brew install gh (macOS) |
| HTTP 401: Unauthorized | Not authenticated | Run: gh auth login |
| HTTP 404: Not Found | Repo doesn't exist or private | Check name, or authenticate |
| unknown flag: --xyz | Wrong flag syntax | Check: gh <cmd> --help |
| Resource not accessible | Insufficient permissions | Run: gh auth refresh -s repo |
| API rate limit exceeded | Too many requests | Authenticate for 5000/hr limit |
When command fails: Read error → check gh <cmd> --help → try once more → report to user if still fails.
DO NOT try multiple blind variations.
For operations not covered by gh subcommands, use gh api directly:
gh api repos/OWNER/REPO # Get repo info
gh api repos/OWNER/REPO/commits # List commits
gh api repos/OWNER/REPO/issues/NUMBER --jq '.title,.state'
Prefer standard commands when available - simpler and more reliable.
See REFERENCES.md for GraphQL examples.
Install: brew install gh (macOS) or see REFERENCES.md. Then: gh auth login
License: MIT | See also: REFERENCES.md
development
Create production-grade frontend interfaces with strong UX and visual craft. Use when building web components, pages, dashboards, forms, landing pages, or any UI. Use when user says 'build a form', 'create a dashboard', 'design a component', 'make a landing page', or asks for UI/UX work.
development
Create, fix, and validate skills for AI agents. Use when user says 'create a skill', 'write a skill', 'build a skill', 'fix my skill', 'skill not working', 'analyze my skill', 'run skill analysis', 'validate skill', 'audit my skills', 'check character budget', 'create a skill from this session', 'turn this into a skill', 'make this reusable', 'can this become a skill', 'could we create a skill', 'should this be a skill', 'check if this could be a skill', or 'any reusable patterns in this session'.
tools
JVM dependency intelligence via Maven Tools MCP server. Use when user asks about Java/Kotlin/Scala dependencies, versions, upgrades, CVEs, or licenses. Use when analyzing pom.xml, build.gradle, or any Maven Central dependency. Use when user says 'check my dependencies', 'should I upgrade X', 'is this version safe', or 'what's the latest version of Y'.
tools
Fetch up-to-date library documentation via Context7 REST API. Use when needing current API docs, framework patterns, or code examples for any library. Use when user asks about React, Next.js, Prisma, Express, Vue, Angular, Svelte, or any npm/PyPI package. Use when user says 'how do I use X library', 'what's the API for Y', or needs official documentation. Lightweight alternative to Context7 MCP with no persistent context overhead.