Token导航 LogoToken导航TokenDH.com
研究检索操作浏览器clawhub未标认证来源可访问clear审计通过

gh-completegh 完成

Agent Skill

gh-complete 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

2,970

周安装

125

GitHub Stars

公开资料未说明

下载量

1,040
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:gh-complete(gh 完成)
来源仓库:https://github.com/iiroak/gh-complete
安装命令:
openclaw skills install gh-complete
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install gh-complete

简介

gh-complete 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。

  • 在 cli-trunk 上操作 GitHub CLI (gh) 的完整技能,包括完整的命令图、子命令、使用模式、JSON 输出以及问题、PR 的实用工作流程。
  • 通过 clawhub 安装,命令为 openclaw skills install gh-complete。
  • 安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。
  • 适用宿主包括 OpenClaw,接入前应确认版本、权限和运行环境要求。

SKILL.md

name
gh-view
description
Complete skill for operating GitHub CLI (gh) on cli-trunk: full command map, subcommands, usage patterns, JSON output, and practical workflows for Issues, PRs, Actions, Repos, Releases, Projects, Secrets, Variables, Codespaces, Extensions, and API.

Skill: Complete GitHub CLI (cli-trunk)

Use gh to operate GitHub end-to-end from the command line. This skill is built from the cli-trunk source code and is meant for practical, reproducible command execution.

Goal

  • Solve GitHub tasks with precise and repeatable gh commands.
  • Pick the right command family by domain: PRs, Issues, repositories, Actions, releases, configuration, security, and API.
  • Prefer structured output (--json, --jq) whenever automation is needed.

Install GitHub CLI on Linux

Use official packages when possible.

Debian and Ubuntu (official repository)

(type -p wget >/dev/null || (sudo apt update && sudo apt install wget -y)) \
  && sudo mkdir -p -m 755 /etc/apt/keyrings \
  && out=$(mktemp) && wget -nv -O$out https://cli.github.com/packages/githubcli-archive-keyring.gpg \
  && cat $out | sudo tee /etc/apt/keyrings/githubcli-archive-keyring.gpg > /dev/null \
  && sudo chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg \
  && sudo mkdir -p -m 755 /etc/apt/sources.list.d \
  && echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null \
  && sudo apt update \
  && sudo apt install gh -y

Upgrade:

sudo apt update
sudo apt install gh

RPM-based distros (DNF5)

sudo dnf install dnf5-plugins
sudo dnf config-manager addrepo --from-repofile=https://cli.github.com/packages/rpm/gh-cli.repo
sudo dnf install gh --repo gh-cli

Upgrade:

sudo dnf update gh

RPM-based distros (DNF4)

sudo dnf install 'dnf-command(config-manager)'
sudo dnf config-manager --add-repo https://cli.github.com/packages/rpm/gh-cli.repo
sudo dnf install gh --repo gh-cli

Amazon Linux 2 (yum)

type -p yum-config-manager >/dev/null || sudo yum install yum-utils
sudo yum-config-manager --add-repo https://cli.github.com/packages/rpm/gh-cli.repo
sudo yum install gh

openSUSE and SUSE (zypper)

sudo zypper addrepo https://cli.github.com/packages/rpm/gh-cli.repo
sudo zypper ref
sudo zypper install gh

Alternative official methods

  • Homebrew on Linux:
brew install gh
  • Precompiled binaries: https://github.com/cli/cli/releases/latest

Verify installation

gh --version

Login and Authentication (Do This First)

Most gh commands require authentication. Use one of these methods.

Interactive login (recommended for local development)

gh auth login
gh auth status
gh auth setup-git

What this does:

  • gh auth login: signs you in (browser/device flow) and stores credentials.
  • gh auth status: confirms active account, host, and token scopes.
  • gh auth setup-git: configures git credential helper integration.

GitHub Enterprise Server login

gh auth login --hostname github.example.com
gh auth status --hostname github.example.com

Token-based login (CI/non-interactive)

export GH_TOKEN=<your_token>
gh auth status

Notes:

  • GH_TOKEN / GITHUB_TOKEN are used for github.com.
  • GH_ENTERPRISE_TOKEN / GITHUB_ENTERPRISE_TOKEN are used for GHES hosts.

Common auth lifecycle commands

gh auth refresh -s repo,read:org,project
gh auth switch
gh auth logout
  • gh auth refresh: updates token scopes.
  • gh auth switch: switches between authenticated accounts/hosts.
  • gh auth logout: removes stored credentials for a host.

Notes:

  • Official Linux installation documentation in this repo: cli-trunk/docs/install_linux.md.
  • Recommended official package host: https://cli.github.com/

Operating Rules

  • If you are not inside a local git repository, use --repo OWNER/REPO or a full URL.
  • For automation, prefer:

- --json <fields> for structured output. - --jq '<filter>' for JSON filtering.

  • For large listings and searches, cap output with --limit.
  • If no dedicated subcommand exists, use gh api.

Syntax and Patterns

  • Required placeholder: <value>.
  • Optional argument: [--flag] or [<arg>].
  • Exclusive alternatives: {a | b} or [a | b] depending on required vs optional.
  • Repeatable arguments: <arg>....

Root Commands (Complete Map)

  • gh pr (pull requests)
  • gh issue (issues)
  • gh repo (repositories)
  • gh release (releases)
  • gh run (workflow runs)
  • gh workflow (workflows)
  • gh auth (authentication)
  • gh config (configuration)
  • gh project (GitHub Projects)
  • gh secret (secrets)
  • gh variable (Actions variables)
  • gh search (global search)
  • gh gist (gists)
  • gh extension / gh ext (extensions)
  • gh codespace / gh cs (Codespaces)
  • gh org (organizations)
  • gh ruleset / gh rs (rulesets)
  • gh cache (Actions cache)
  • gh label (labels)
  • gh ssh-key (SSH keys)
  • gh gpg-key (GPG keys)
  • gh attestation / gh at (artifact attestations)
  • gh agent-task / gh agent (preview)
  • gh api (REST/GraphQL API)
  • gh browse (open in browser)
  • gh status (cross-repo status)
  • gh copilot (preview)
  • gh completion (shell completion)
  • gh licenses (third-party licenses)
  • gh preview (experimental commands)
  • gh actions (hidden; guidance text)
  • gh accessibility / gh a11y (hidden; accessibility)
  • gh credits (hidden)
  • gh version (hidden)

Subcommands by Domain

Pull Requests: gh pr

  • list, create, status
  • view, diff, checkout, checks, review, merge, update-branch, ready, comment, close, reopen, revert, edit, lock, unlock

Examples:

gh pr list --repo OWNER/REPO --limit 20
gh pr view 123 --repo OWNER/REPO --json number,title,state,author
gh pr checks 123 --repo OWNER/REPO

Issues: gh issue

  • list, create, status
  • view, comment, close, reopen, edit, develop, lock, unlock, pin, unpin, transfer, delete

Examples:

gh issue list --repo OWNER/REPO --limit 50
gh issue view 456 --repo OWNER/REPO --json number,title,state,labels
gh issue create --repo OWNER/REPO --title "Bug" --body "Details"

Repositories: gh repo

  • list, create
  • view, clone, fork, set-default, sync, edit, deploy-key, license, gitignore, rename, archive, unarchive, delete, credits, garden, autolink

Examples:

gh repo view OWNER/REPO --web
gh repo list OWNER --limit 100
gh repo sync OWNER/REPO

Releases: gh release

  • list, create
  • view, edit, upload, download, delete, delete-asset, verify, verify-asset

Examples:

gh release list --repo OWNER/REPO
gh release view v1.2.3 --repo OWNER/REPO
gh release download v1.2.3 --repo OWNER/REPO

GitHub Actions: gh run, gh workflow, gh cache

  • gh run: list, view, rerun, download, watch, cancel, delete
  • gh workflow: list, enable, disable, view, run
  • gh cache: list, delete

Examples:

gh run list --repo OWNER/REPO --limit 10
gh run view <run-id> --repo OWNER/REPO --log-failed
gh workflow run ci.yml --repo OWNER/REPO

Authentication and Config: gh auth, gh config

  • gh auth: login, logout, status, refresh, git-credential, setup-git, token, switch
  • gh config: get, set, list, clear-cache

Examples:

gh auth status
gh auth refresh -s repo,read:org
gh config set git_protocol ssh

Projects: gh project

  • Project-level: list, create, copy, close, delete, edit, link, view, mark-template, unlink
  • Items: item-list, item-create, item-add, item-edit, item-archive, item-delete
  • Fields: field-list, field-create, field-delete

Examples:

gh project list --owner ORG
gh project view 1 --owner ORG --web
gh project item-list 1 --owner ORG

Secrets and Variables: gh secret, gh variable

  • gh secret: list, set, delete
  • gh variable: get, set, list, delete

Examples:

gh secret list --repo OWNER/REPO
gh secret set MY_SECRET --repo OWNER/REPO --body "value"
gh variable set MY_VAR --repo OWNER/REPO --body "value"

Global Search: gh search

  • code, commits, issues, prs, repos

Examples:

gh search prs "is:open review:required org:ORG"
gh search code "function NewCmd" --repo OWNER/REPO

PowerShell note: for queries containing negative qualifiers (-qualifier), use stop-parsing with --%.

Gists, Labels, and Keys

  • gh gist: clone, create, list, view, edit, delete, rename
  • gh label: list, create, clone, edit, delete
  • gh ssh-key: add, delete, list
  • gh gpg-key: add, delete, list

Codespaces: gh codespace (gh cs)

  • code, create, edit, delete, jupyter, list, view, logs, ports, ssh, cp, stop, select, rebuild

Examples:

gh cs list
gh cs ssh -c <codespace>
gh cs ports -c <codespace>

Extensions: gh extension (gh ext)

  • search, list, install, upgrade, remove, browse, exec, create

Examples:

gh ext search
gh ext install owner/gh-myext
gh ext exec myext -- --help

Rulesets, Org, Attestation, Agent Task

  • gh ruleset: list, view, check
  • gh org: list
  • gh attestation: download, inspect, verify, trustedroot
  • gh agent-task (preview): list, create, view

Examples:

gh ruleset list --repo OWNER/REPO
gh at verify -R OWNER/REPO ./artifact.zip
gh agent-task list

Useful Standalone Commands

  • gh browse (issues, PRs, paths, commits, settings, releases, wiki, actions)
  • gh api (authenticated REST/GraphQL)
  • gh status (issues, PRs, mentions, activity)
  • gh copilot (preview)
  • gh completion -s {bash|zsh|fish|powershell}
  • gh licenses

Complete Command Explanations (All Root Commands)

This section explains each root command in plain language and points to its key subcommands.

Collaboration and Code Review

  • gh pr: manage pull requests from creation to merge.

- Main subcommands: list, view, create, status, checks, review, merge, checkout, diff, update-branch, ready, comment, edit, close, reopen, revert, lock, unlock.

  • gh issue: manage issue lifecycle and discussion.

- Main subcommands: list, view, create, status, comment, edit, develop, close, reopen, transfer, delete, pin, unpin, lock, unlock.

  • gh label: create and maintain repository labels.

- Main subcommands: list, create, clone, edit, delete.

Repositories and Releases

  • gh repo: administer repositories.

- Main subcommands: list, view, create, clone, fork, sync, set-default, edit, rename, archive, unarchive, delete, autolink, deploy-key, license, gitignore, credits, garden.

  • gh release: create, publish, inspect, and verify releases.

- Main subcommands: list, view, create, edit, upload, download, delete, delete-asset, verify, verify-asset.

  • gh gist: work with GitHub Gists.

- Main subcommands: list, view, create, edit, rename, clone, delete.

Actions, CI, and Workflow Automation

  • gh run: inspect and control workflow runs.

- Main subcommands: list, view, watch, rerun, download, cancel, delete.

  • gh workflow: inspect and trigger workflow files.

- Main subcommands: list, view, run, enable, disable.

  • gh cache: manage GitHub Actions cache entries.

- Main subcommands: list, delete.

Projects, Organization, and Governance

  • gh project: manage GitHub Projects (project, item, and field operations).

- Main subcommands: list, view, create, edit, delete, copy, close, link, unlink, mark-template, plus item-* and field-* families.

  • gh org: organization-level operations.

- Main subcommands: list.

  • gh ruleset: inspect and evaluate repository rulesets.

- Main subcommands: list, view, check.

Security, Secrets, and Identity

  • gh auth: account and token authentication lifecycle.

- Main subcommands: login, status, refresh, setup-git, token, switch, logout, git-credential.

  • gh secret: manage secrets at repository/org/environment/user scope.

- Main subcommands: list, set, delete.

  • gh variable: manage Actions/Dependabot variables.

- Main subcommands: list, get, set, delete.

  • gh ssh-key: manage SSH keys on your GitHub account.

- Main subcommands: list, add, delete.

  • gh gpg-key: manage GPG keys on your GitHub account.

- Main subcommands: list, add, delete.

  • gh attestation: download, inspect, and verify artifact attestations.

- Main subcommands: download, inspect, verify, trustedroot.

Discovery and Navigation

  • gh search: search code, commits, issues, PRs, and repositories on GitHub.

- Main subcommands: code, commits, issues, prs, repos.

  • gh browse: open repo pages, files, issues, PRs, commits, and settings in your browser.

- Useful flags: --branch, --commit, --settings, --wiki, --projects, --actions, --blame, --no-browser.

  • gh status: aggregated dashboard of assigned issues, PRs, review requests, mentions, and activity.

- Useful flags: --org, --exclude.

Extensions, Aliases, and Developer Experience

  • gh extension (gh ext): discover/install/manage CLI extensions.

- Main subcommands: search, list, install, upgrade, remove, browse, exec, create.

  • gh alias: create and manage command shortcuts.

- Main subcommands: set, list, delete, import.

  • gh completion: generate shell completion scripts.

- Main usage: gh completion -s bash|zsh|fish|powershell.

  • gh config: read and update CLI behavior.

- Main subcommands: get, set, list, clear-cache.

API and Advanced Power Tools

  • gh api: send authenticated REST/GraphQL requests when built-in subcommands are not enough.

- Important options: --method, --field, --raw-field, --input, --paginate, --slurp, --jq, --template, --header, --hostname, --preview.

  • gh codespace (gh cs): manage Codespaces.

- Main subcommands: list, create, view, edit, logs, ports, ssh, stop, delete, rebuild, code, cp, jupyter, select.

  • gh agent-task (gh agent) (preview): create/list/view Copilot agent tasks.

- Main subcommands: create, list, view.

  • gh copilot (preview): run GitHub Copilot CLI via gh.

Informational and Hidden Commands

  • gh licenses: view third-party license info for the current gh build.
  • gh preview: run unstable preview commands (currently includes preview tools such as prompter).
  • gh actions (hidden): informational help text about Actions command groups.
  • gh accessibility / gh a11y (hidden): accessibility guidance and related configuration pointers.
  • gh credits (hidden): credits animation/static credits.
  • gh version (hidden): print current gh version/build info.

Advanced API Usage

Use gh api when no dedicated subcommand exists or when you need custom payload/query control.

REST examples:

gh api repos/{owner}/{repo}/pulls/123
gh api repos/{owner}/{repo}/issues -X GET -f state=open -f per_page=100

GraphQL examples:

gh api graphql -f query='query { viewer { login } }'
gh api graphql --paginate -f query='query($endCursor: String) { viewer { repositories(first: 100, after: $endCursor) { nodes { nameWithOwner } pageInfo { hasNextPage endCursor } } } }'

Quick Recipes by Intent

  • Show PRs with failing checks:
gh pr list --repo OWNER/REPO --json number,title,statusCheckRollup --jq '.[] | select(any(.statusCheckRollup[]?; .conclusion=="FAILURE")) | {number,title}'
  • Get open issues in a compact format:
gh issue list --repo OWNER/REPO --json number,title,author --jq '.[] | "#\(.number) \(.title) (@\(.author.login))"'
  • Fast Actions diagnosis:
gh run list --repo OWNER/REPO --limit 5
gh run view <run-id> --repo OWNER/REPO --log-failed

Command Selection Heuristic

  • If the task is about PRs or Issues, start with gh pr or gh issue.
  • If it is CI/CD related, use gh run, gh workflow, and gh cache.
  • If it is repository administration, use gh repo.
  • If it is governance/security, use gh ruleset, gh secret, gh variable, and gh attestation.
  • If no clear coverage exists, use gh api.

Diagnostics and Common Errors

  • Authentication issues: run gh auth status, then gh auth login or gh auth refresh -s <scopes>.
  • Unresolved repository context: run inside a valid git repo or pass --repo OWNER/REPO.
  • Ambiguous PR/Issue selectors: use full URL or explicit number.
  • In scripts, avoid human-oriented output; use --json + --jq.

Completeness Criterion

This skill covers the full command catalog visible in pkg/cmd/root/root.go and subcommands registered in pkg/cmd/* modules within cli-trunk.

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

88.47%
按下载量换算920

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills