plugins-claude/git-cli/skills/git-cli/SKILL.md
This skill MUST be used for ALL GitHub and Gitea CLI operations. Never run `gh`, `tea`, `gh issue`, `gh pr`, `gh run`, `gh api`, `gh repo`, `tea issues`, or `tea pr` directly — always use git-cli instead. This skill should be used when the user asks to "list issues", "show issue", "file a bug", "create issue", "comment on issue", "list PRs", "show PR", "create PR", "merge PR", "check CI", "view run logs", "check build status", or any interaction with GitHub or Gitea issue trackers, pull requests, or CI systems. Provides a unified wrapper that auto-detects the platform from the git remote.
npx skillsauth add st0nefish/claude-toolkit git-cliInstall 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.
CRITICAL: Never run gh or tea directly. Always use the wrapper script below.
The current repository may use GitHub or Gitea — the wrapper auto-detects the platform
from the git remote so the correct CLI is used every time. Running gh directly will
fail on Gitea repositories and vice versa.
# List open issues (returns normalized JSON array)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue list [--limit N] [--state open|closed|all] [--label LABEL] [--assignee USER]
# Show a single issue with full body and comments
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue show <number>
# Create an issue (pipe body to --body via heredoc)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue create --title "Title" --body [--label bug] <<'EOF'
## Problem
...
EOF
# Add a comment (heredoc for multi-line, printf for short)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue comment <number> --body <<'EOF'
Progress update...
EOF
printf 'LGTM' | ${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue comment <number> --body
# Close or reopen
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue close <number>
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue reopen <number>
# List PRs
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli pr list [--state open|closed|merged|all] [--limit N]
# Show a single PR with details
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli pr show <number>
# Create a PR (auto-assigns to current user; --base defaults to repo's primary branch)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli pr create --title "Title" --head branch [--base main] --body <<'EOF'
## Summary
...
## Test plan
...
EOF
# Comment on a PR
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli pr comment <number> --body <<'EOF'
Review follow-up...
EOF
# Merge or close
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli pr merge <number> [--squash | --rebase]
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli pr close <number>
# Wait for a PR to merge (polls until merged, closed, or timeout)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli pr wait --branch NAME [--timeout 300] [--interval 15]
# List recent runs (JSON with id, status, workflow, branch, event, started_at)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli run list [--limit N] [--status failure|success|pending] [--branch BRANCH]
# Show details of a specific run
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli run show <run-id>
# Fetch logs (--failed-only shows only failing steps on GitHub)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli run logs <run-id>
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli run logs <run-id> --failed-only
# Watch for CI completion (polls until pass/fail/timeout)
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli run watch --branch NAME [--initial-delay S] [--timeout S] [--interval S]
# Outputs: status (pass|fail|closed|timeout|no-workflow), url, duration
# On fail: also emits failed_jobs: <comma-separated names> and dumps failed job logs to stderr
# On GitHub with a PR: uses statusCheckRollup for reliable CI + merge state detection
# Without a PR: falls back to run list polling
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli repo default-branch # e.g. "main" or "master"
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli repo info # name, description, stars, etc.
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli user whoami # {"login": "username"}
All commands return JSON. Issue and PR objects use a normalized schema:
{
"number": 42,
"title": "...",
"body": "...",
"state": "open",
"author": "username",
"labels": ["bug", "high-priority"],
"milestone": null,
"assignees": ["username"],
"created_at": "2026-01-01T00:00:00Z",
"updated_at": "2026-01-01T00:00:00Z",
"url": "https://..."
}
Pipe the body to --body via a heredoc. No temp file, no cleanup:
${CLAUDE_PLUGIN_ROOT}/scripts/git-cli issue create --title "Bug: ..." --label bug --body <<'EOF'
## Problem
...
## Steps to reproduce
...
EOF
--body-file FILE remains available when the body is already on disk, and
--body-file - is equivalent to --body (reads stdin). There is no
--body TEXT form — stdin handles every size from one-liners to full PR
descriptions.
development
Start work from your description — explore the codebase and plan
data-ai
Multi-phase, multi-agent feature workflow: spec → plan → refine → divide → execute → review. Invoke when the user escalates a session-start/session-issue flow to orchestration, or asks to run a non-trivial feature (multiple files, design ambiguity, cross-cutting concerns, correctness-critical paths) through the full multi-agent workflow. For small fixes, prefer session-start.
tools
Browse open issues, pick one, and start work on it
tools
Interact with GitHub and Gitea issue trackers and CI systems. List and show issues, file bugs, comment on issues or PRs, list and show pull requests, and fetch CI run logs — all from any repo context without leaving the session.