AgentSkillsCN

gh-repo-context

获取 GitHub 仓库的上下文信息,包括仓库所有者、仓库名称、可用的问题类型、标签以及关联的项目。当您需要获取仓库元数据,或探索问题与项目的更多可用选项时,可使用此功能。

SKILL.md
--- frontmatter
name: gh-repo-context
description: Get GitHub repository context including owner, repo name, available issue types, labels, and linked projects. Use when you need to fetch repo metadata or discover available options for issues/projects.
allowed-tools: Bash, Read

GitHub Repository Context

Provides scripts to dynamically fetch repository information. All scripts auto-detect the current repo.

Available Scripts

get-repo-info.sh

Returns owner, repo name, and default branch.

bash
~/.claude/skills/gh-repo-context/scripts/get-repo-info.sh

get-issue-types.sh

Returns available issue types with their IDs.

bash
~/.claude/skills/gh-repo-context/scripts/get-issue-types.sh

get-labels.sh

Returns available labels for the repo.

bash
~/.claude/skills/gh-repo-context/scripts/get-labels.sh

get-projects.sh

Returns linked projects with their numbers.

bash
~/.claude/skills/gh-repo-context/scripts/get-projects.sh

Usage

Run scripts directly to get JSON output:

bash
bash ~/.claude/skills/gh-repo-context/scripts/get-issue-types.sh

All scripts require being in a git repo with a GitHub remote.