From e94ed52b3a50259ef1e31792a4926addacf378d6 Mon Sep 17 00:00:00 2001 From: codekongdev <349702077+codekongdev@users.noreply.github.com> Date: Tue, 3 Nov 2026 14:05:02 +0900 Subject: [PATCH 1/5] feat: add repository issue setup skill --- AGENTS.md | 8 + README.ja.md | 1 + README.ko.md | 1 + README.md | 1 + README.zh-CN.md | 1 + skills/plz-setup-issues/README.ja.md | 50 ++++++ skills/plz-setup-issues/README.ko.md | 50 ++++++ skills/plz-setup-issues/README.md | 50 ++++++ skills/plz-setup-issues/README.zh-CN.md | 50 ++++++ skills/plz-setup-issues/SKILL.md | 146 ++++++++++++++++++ skills/plz-setup-issues/agents/openai.yaml | 4 + .../assets/ISSUE_TEMPLATE/bug.yml | 41 +++++ .../assets/ISSUE_TEMPLATE/config.yml | 1 + .../assets/ISSUE_TEMPLATE/feature.yml | 33 ++++ skills/plz-setup-issues/assets/labels.json | 13 ++ skills/plz-setup-issues/references/github.md | 69 +++++++++ .../plz-setup-issues/references/taxonomy.md | 99 ++++++++++++ 17 files changed, 618 insertions(+) create mode 100644 AGENTS.md create mode 100644 skills/plz-setup-issues/README.ja.md create mode 100644 skills/plz-setup-issues/README.ko.md create mode 100644 skills/plz-setup-issues/README.md create mode 100644 skills/plz-setup-issues/README.zh-CN.md create mode 100644 skills/plz-setup-issues/SKILL.md create mode 100644 skills/plz-setup-issues/agents/openai.yaml create mode 100644 skills/plz-setup-issues/assets/ISSUE_TEMPLATE/bug.yml create mode 100644 skills/plz-setup-issues/assets/ISSUE_TEMPLATE/config.yml create mode 100644 skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml create mode 100644 skills/plz-setup-issues/assets/labels.json create mode 100644 skills/plz-setup-issues/references/github.md create mode 100644 skills/plz-setup-issues/references/taxonomy.md diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..cc3642d --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,8 @@ +# GitHub account for this repository + +- All authenticated GitHub operations for `codekongdev/plz` must use **`codekongdev`**. This includes issues, pull requests, comments, labels, releases, and pushes. +- Never use another account, including `planit-mason` or `YASICJUNWOO`, as a fallback, even if it is the default CLI or connector account. +- Before a GitHub operation, verify the authenticated login with `gh api user --jq .login` or an equivalent identity check. Use the same credentials for the check and the operation, and proceed only when the login is exactly `codekongdev`. +- The repository owner and the username in the remote URL do not verify the authenticated account. A connector must also pass the identity check before use. +- Prefer credentials scoped to the individual command or process. Do not switch the global GitHub account for other projects, and never print credentials or save them in repository files or logs. +- If `codekongdev` authentication is unavailable or cannot be verified, stop the GitHub operation and report the authentication problem. Do not act under a different account. diff --git a/README.ja.md b/README.ja.md index 3aaab02..36d11b0 100644 --- a/README.ja.md +++ b/README.ja.md @@ -106,6 +106,7 @@ cp -R plz/skills/plz-3d-explain ~/.claude/skills/plz-3d-explain | スキル | 作成するもの | デモ | | --- | --- | --- | | [plz-3d-explain](skills/plz-3d-explain/README.md) | 技術的な概念やシステム構成を three.js の 3D モデルで学べる、単一 HTML ファイルの学習ページ。 | [コードサンドボックス(英語)](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.en.html) · [韓国語](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.html) | +| [plz-setup-issues](skills/plz-setup-issues/README.md) | GitHub リポジトリの Issue ラベル、バグ・機能リクエストフォーム、トリアージ規則を設定します。 | — | ## コントリビュート diff --git a/README.ko.md b/README.ko.md index 5bb76d9..c45c63b 100644 --- a/README.ko.md +++ b/README.ko.md @@ -106,6 +106,7 @@ cp -R plz/skills/plz-3d-explain ~/.claude/skills/plz-3d-explain | 스킬 | 만드는 것 | 데모 | | --- | --- | --- | | [plz-3d-explain](skills/plz-3d-explain/README.md) | 기술 개념과 시스템 구조를 three.js 3D 모형으로 공부하는 단일 HTML 학습 페이지를 만듭니다. | [코드 샌드박스(한국어)](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.html) · [영어](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.en.html) | +| [plz-setup-issues](skills/plz-setup-issues/README.md) | GitHub 저장소의 이슈 라벨, 버그·기능 요청 양식, 검토 규칙을 세팅합니다. | — | ## 기여 diff --git a/README.md b/README.md index 0347cdd..d147373 100644 --- a/README.md +++ b/README.md @@ -106,6 +106,7 @@ Details are in the [skill README](skills/plz-3d-explain/README.md). | Skill | What it makes | Demo | | --- | --- | --- | | [plz-3d-explain](skills/plz-3d-explain/README.md) | A single HTML learning page with three.js 3D models of technical concepts and system structures. | [Code sandbox (English)](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.en.html) · [Korean](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.html) | +| [plz-setup-issues](skills/plz-setup-issues/README.md) | Issue labels, bug and feature forms, and triage rules for a GitHub repository. | — | ## Contributing diff --git a/README.zh-CN.md b/README.zh-CN.md index a9e75f1..a0ae90f 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -106,6 +106,7 @@ cp -R plz/skills/plz-3d-explain ~/.claude/skills/plz-3d-explain | 技能 | 生成内容 | 演示 | | --- | --- | --- | | [plz-3d-explain](skills/plz-3d-explain/README.md) | 用 three.js 3D 模型讲解技术概念和系统结构的单文件 HTML 学习页面。 | [代码沙箱(英语)](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.en.html) · [韩语](https://codekongdev.github.io/plz/skills/plz-3d-explain/assets/example-agent-sandbox.html) | +| [plz-setup-issues](skills/plz-setup-issues/README.md) | 设置 GitHub 仓库的议题标签、缺陷与功能请求表单和分诊规则。 | — | ## 参与贡献 diff --git a/skills/plz-setup-issues/README.ja.md b/skills/plz-setup-issues/README.ja.md new file mode 100644 index 0000000..5ee1023 --- /dev/null +++ b/skills/plz-setup-issues/README.ja.md @@ -0,0 +1,50 @@ +# plz-setup-issues +[English](README.md) | [한국어](README.ko.md) | 日本語 | [简体中文](README.zh-CN.md) + +GitHub リポジトリに、再利用できる簡潔な Issue 分類、フォーム、トリアージ規則を設定します。Claude Code と Codex に対応し、[plz](../../README.md) に含まれるスキルです。 + +## インストール + +グローバルにインストール: + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -g +``` + +Codex では `-a codex` を付けます。以下のコマンドは現在のプロジェクトの `.agents/skills/` にインストールします。 + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -a codex +``` + +## 使い方 + +Claude Code: + +```text +/plz-setup-issues Set up issue management in this repository. +``` + +Codex: + +```text +$plz-setup-issues Set up issue management in this repository. +``` + +ローカルファイルの作成のみを依頼することも、特定の GitHub リポジトリへのラベル適用を明示的に依頼することもできます。変更前に既存の設定を確認し、競合する規則は解決方針が決まるまで保持します。 + +## デフォルト構成 + +- 種類ラベル 5 個: `type:bug`、`type:feature`、`type:improvement`、`type:maintenance`、`type:docs`。 +- 検討用ラベル 2 個: `needs-triage`、`needs-info`。 +- バグ・機能リクエストフォーム、`.github/ISSUE_TRIAGE.md`、`.github/labels.json`。 +- P0–P3 優先度: 既存のプロジェクト・組織フィールドを再利用し、なければ `priority:P0`–`priority:P3` ラベルで管理します。プロジェクトボードは自動作成しません。 +- 領域・影響度・顧客の分類は必要な場合だけ追加します。 + +種類の主な分類には、リポジトリの種類ラベルか組織の Issue Type のいずれかを用い、同じ分類を重複管理しません。 + +## 対象範囲 + +設定の依頼は対象リポジトリに適用します。組織全体の種類変更、プロジェクトボードの作成、既存 Issue の再分類は、それぞれ依頼の範囲に含まれている必要があります。GitHub の変更には適切な認証と権限が必要ですが、利用できない場合もローカルの準備は完了できます。 + +手順は [SKILL.md](SKILL.md)、分類の判断基準は[分類ガイド](references/taxonomy.md)、デフォルトラベルは[ラベル一覧ファイル](assets/labels.json)を参照してください。 diff --git a/skills/plz-setup-issues/README.ko.md b/skills/plz-setup-issues/README.ko.md new file mode 100644 index 0000000..ccb0aee --- /dev/null +++ b/skills/plz-setup-issues/README.ko.md @@ -0,0 +1,50 @@ +# plz-setup-issues +[English](README.md) | 한국어 | [日本語](README.ja.md) | [简体中文](README.zh-CN.md) + +GitHub 저장소에 재사용할 수 있는 간결한 이슈 분류, 이슈 양식, 검토 규칙을 세팅합니다. Claude Code와 Codex에서 사용할 수 있으며, [plz](../../README.md)에 포함된 스킬입니다. + +## 설치 + +전역으로 설치: + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -g +``` + +Codex에서 쓰려면 `-a codex`를 붙입니다. 아래 명령은 현재 프로젝트의 `.agents/skills/`에 설치합니다. + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -a codex +``` + +## 사용법 + +Claude Code: + +```text +/plz-setup-issues Set up issue management in this repository. +``` + +Codex: + +```text +$plz-setup-issues Set up issue management in this repository. +``` + +로컬 파일만 만들도록 요청하거나, 특정 GitHub 저장소에 라벨까지 적용하도록 명시할 수 있습니다. 변경 전에 기존 설정을 확인하며, 충돌하는 규칙은 해결 방향이 정해질 때까지 보존합니다. + +## 기본 구성 + +- 작업 유형 라벨 5개: `type:bug`, `type:feature`, `type:improvement`, `type:maintenance`, `type:docs`. +- 검토 라벨 2개: `needs-triage`, `needs-info`. +- 버그·기능 요청 양식, `.github/ISSUE_TRIAGE.md`, `.github/labels.json`. +- P0–P3 우선순위: 기존 프로젝트·조직 필드가 있으면 재사용하고, 없으면 `priority:P0`–`priority:P3` 라벨로 관리합니다. 프로젝트 보드는 자동 생성하지 않습니다. +- 영역·영향도·고객사 분류는 필요한 경우에만 추가합니다. + +작업 유형은 저장소의 유형 라벨 또는 조직의 Issue Type 중 하나를 주된 체계로 사용해 같은 분류를 중복 관리하지 않습니다. + +## 범위 + +세팅 요청은 대상 저장소에 적용됩니다. 조직 전체 유형 변경, 프로젝트 보드 생성, 기존 이슈 재분류는 별도로 요청한 범위에 포함되어야 합니다. GitHub 변경에는 적절한 인증과 권한이 필요하며, 사용할 수 없어도 로컬 준비는 마칠 수 있습니다. + +진행 절차는 [SKILL.md](SKILL.md), 분류를 정하는 기준은 [분류 가이드](references/taxonomy.md), 기본 라벨은 [라벨 목록 파일](assets/labels.json)을 참고하세요. diff --git a/skills/plz-setup-issues/README.md b/skills/plz-setup-issues/README.md new file mode 100644 index 0000000..a81e246 --- /dev/null +++ b/skills/plz-setup-issues/README.md @@ -0,0 +1,50 @@ +# plz-setup-issues +English | [한국어](README.ko.md) | [日本語](README.ja.md) | [简体中文](README.zh-CN.md) + +Set up issue management for a GitHub repository with a small, reusable taxonomy, issue forms, and written triage rules. Works with Claude Code and Codex. Part of [plz](../../README.md). + +## Install + +Install globally: + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -g +``` + +For Codex, add `-a codex`. This installs into the current project's `.agents/skills/` directory: + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -a codex +``` + +## Usage + +Claude Code: + +```text +/plz-setup-issues Set up issue management in this repository. +``` + +Codex: + +```text +$plz-setup-issues Set up issue management in this repository. +``` + +You can request local files only, or explicitly ask to apply labels to a named GitHub repository. Existing settings are inspected before changes, and conflicting conventions are preserved until resolved. + +## Defaults + +- Five type labels: `type:bug`, `type:feature`, `type:improvement`, `type:maintenance`, and `type:docs`. +- Two review labels: `needs-triage` and `needs-info`. +- Bug and feature issue forms, `.github/ISSUE_TRIAGE.md`, and `.github/labels.json`. +- P0–P3 priority: reuse an existing project or organization field; otherwise use `priority:P0`–`priority:P3` labels. No project board is created automatically. +- Area, impact, and customer categories are added only when useful. + +The skill uses one primary type system: repository type labels or organization Issue Types. It avoids duplicating the same classification across both. + +## Scope + +A setup request covers the target repository. Changing organization-wide types, creating a project board, and reclassifying existing issues require their own requested scope. GitHub changes need suitable authentication and permissions; local preparation can still be completed when these are unavailable. + +See [SKILL.md](SKILL.md) for the workflow, [the taxonomy guide](references/taxonomy.md) for decisions, and [the label manifest](assets/labels.json) for default labels. diff --git a/skills/plz-setup-issues/README.zh-CN.md b/skills/plz-setup-issues/README.zh-CN.md new file mode 100644 index 0000000..fb7036e --- /dev/null +++ b/skills/plz-setup-issues/README.zh-CN.md @@ -0,0 +1,50 @@ +# plz-setup-issues +[English](README.md) | [한국어](README.ko.md) | [日本語](README.ja.md) | 简体中文 + +为 GitHub 仓库设置可复用的精简议题分类、议题表单和分诊规则。支持 Claude Code 和 Codex,是 [plz](../../README.md) 的一部分。 + +## 安装 + +全局安装: + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -g +``` + +在 Codex 中使用时加上 `-a codex`。以下命令安装到当前项目的 `.agents/skills/` 目录: + +```sh +npx skills add codekongdev/plz --skill plz-setup-issues -a codex +``` + +## 使用方法 + +Claude Code: + +```text +/plz-setup-issues Set up issue management in this repository. +``` + +Codex: + +```text +$plz-setup-issues Set up issue management in this repository. +``` + +可以只请求生成本地文件,也可以明确要求向指定的 GitHub 仓库应用标签。修改前会检查现有设置,冲突的规则会保留,直到确定解决方案。 + +## 默认配置 + +- 5 个类型标签:`type:bug`、`type:feature`、`type:improvement`、`type:maintenance`、`type:docs`。 +- 2 个审查标签:`needs-triage` 和 `needs-info`。 +- 缺陷与功能请求表单、`.github/ISSUE_TRIAGE.md` 和 `.github/labels.json`。 +- P0–P3 优先级:复用现有项目或组织字段;没有时使用 `priority:P0`–`priority:P3` 标签。不会自动创建项目看板。 +- 仅在有用时添加领域、影响程度和客户分类。 + +主要类型分类采用仓库类型标签或组织 Issue Type 中的一种,避免对同一分类进行重复管理。 + +## 范围 + +设置请求适用于目标仓库。修改组织级类型、创建项目看板以及重新分类现有议题,需要分别包含在请求范围内。GitHub 修改需要适当的身份验证和权限;即使不可用,也可以完成本地准备。 + +工作流程见 [SKILL.md](SKILL.md),分类决策见[分类指南](references/taxonomy.md),默认标签见[标签清单](assets/labels.json)。 diff --git a/skills/plz-setup-issues/SKILL.md b/skills/plz-setup-issues/SKILL.md new file mode 100644 index 0000000..9a9f6e5 --- /dev/null +++ b/skills/plz-setup-issues/SKILL.md @@ -0,0 +1,146 @@ +--- +name: plz-setup-issues +description: | + Set up a reusable GitHub issue-management baseline for a new repository: work types, + triage labels, priorities, bug and feature forms, and a short operating guide. + Adapt to existing labels, organization Issue Types, and project fields without + overwriting established conventions. Use for initial issue setup or a requested + refresh of that setup, not for filing individual issues or bulk reclassifying a backlog. + Triggers: "set up issue management", "initialize issue labels and templates", + "이슈 관리 초기 세팅", "이슈 라벨이랑 템플릿 설정해줘", + "Issue 管理を初期設定して", "初始化仓库的问题分类和模板". +--- + +# Set up repository issues + +Create a small issue-management system that fits the target repository. This skill +works in Claude Code and Codex using ordinary file operations and available GitHub +tools; GitHub CLI (`gh`) is a fallback, not a required agent-specific integration. +Resolve paths in this document relative to this skill's directory. + +## Establish the target and scope + +Read the target repository's `AGENTS.md`, `CLAUDE.md`, contribution guide, existing +issue templates, and issue-management instructions. Inspect the working tree before +editing. Resolve the intended GitHub repository from the user's request and remotes; +if a fork or several remotes make the destination ambiguous, prepare local files +and ask which remote to use before changing GitHub. + +- A request to draft or generate templates authorizes local artifacts. +- A request to set up issue management in an identified GitHub repository authorizes + the necessary repository labels as well as local configuration. Explain the concrete + additions before applying them; do not ask again for scope already authorized. +- Creating this skill, installing it, or discussing possible conventions does not + authorize applying it to the current repository. +- Organization-wide types/fields, creating or changing shared boards, existing-issue + relabeling, commits, pushes, and PR creation require corresponding user scope. + Finish independent local work if remote access or scope is unavailable. + +Use the repository's required GitHub account, if specified. Before authenticated +GitHub operations, verify the active login with the same credentials used for those +operations. Do not change a global account as a shortcut. + +## Choose the baseline + +Read [references/taxonomy.md](references/taxonomy.md) for definitions and examples. +Start from these defaults and preserve an established equivalent convention: + +| Axis | Default | Where it lives | +| --- | --- | --- | +| Work type | bug, feature, improvement, maintenance, docs | Exactly one `type:*` label | +| Review needed | `needs-triage`, `needs-info` | Labels | +| Priority | P0, P1, P2, P3; unset until assessed | Existing Priority field, otherwise `priority:*` labels | +| Progress | Backlog, Ready, In progress, Done | Existing board if present | + +Do not create a board just to represent progress. With no board, open/closed issues, +assignees, and linked PRs are sufficient until a board is requested. If a board is +already established, retain its status options; `In review` is optional. + +### Select one source for each value + +- For a new or personal repository without a suitable organization convention, use + `type:*` labels. This works independently of organization administration. +- If the organization already uses Issue Types, reuse their exact existing names + and definitions. Map feature/improvement to Feature and maintenance/docs to Task + when using the standard Bug/Feature/Task set. Explain that this intentionally + merges the finer categories. Do not also add `type:*` labels by default. +- If the user explicitly wants detailed labels alongside broader native types, + document their mapping and keep them consistent; do not create organization types. +- Reuse an existing Priority issue field or project field. Do not create priority + labels for the same value. Otherwise use the four bundled `priority:*` labels. +- A denied or unavailable field/type lookup is not evidence that nothing exists. + Preserve local conventions, report the limitation, and ask only if it blocks a + necessary choice. + +Area labels, Impact/Severity, customers, platforms, versions, contributor labels, +release blockers, and automatic stale closing are extensions, not baseline defaults. +Add them only when supported by the repository's needs or requested explicitly. +Do not import domains, customer names, or operating rules from a different project. + +## Generate repository files + +Use the prose language already used by the repository unless the user specifies +another. Translate form names, field text, label descriptions, and the guide; keep +chosen label identifiers stable. The bundled assets are English starting points. + +1. Build `.github/labels.json` from [assets/labels.json](assets/labels.json), including + only the selected labels. Exclude `type:*` for native-type-only setups and + `priority:*` when a Priority field is used. Match existing names when equivalent. + This file is a desired-label manifest, not an automatic synchronization service. +2. Adapt [assets/ISSUE_TEMPLATE/bug.yml](assets/ISSUE_TEMPLATE/bug.yml) and + [assets/ISSUE_TEMPLATE/feature.yml](assets/ISSUE_TEMPLATE/feature.yml) into the + target's `.github/ISSUE_TEMPLATE/`. In native-type mode remove the type label from + `labels` and set the form's top-level `type` to the verified organization type name. + Use `needs-triage` in both forms. Do not preassign priority, area, or people. +3. Merge [assets/ISSUE_TEMPLATE/config.yml](assets/ISSUE_TEMPLATE/config.yml) with any + existing chooser config. Keep blank issues enabled by default so maintainers can + file maintenance/docs work without a mismatched form. Preserve contact links and + security-reporting instructions; do not invent a contact destination. +4. Write or update `.github/ISSUE_TRIAGE.md` with the selected definitions, type and + priority storage, what each form collects, and the review/close procedure from + the taxonomy reference. Document actual choices, not unused alternatives. + +Preserve existing files and user edits. Improve an equivalent existing form in place +instead of adding a competing form. Inspect Markdown templates as well as YAML. +Before setting native Issue Types in an existing Markdown template, verify that +GitHub supports the intended metadata there. If automatic assignment is unavailable +or unverified, retain the template and document manual type selection during triage, +or convert it in place when in scope while preserving its content. Do not invent +frontmatter keys or add a duplicate form to gain YAML-only functionality. +For overlapping changes, merge compatible content and show any substantive policy +conflict instead of overwriting it. Running the skill again should produce no +duplicate forms, labels, or guide sections. Keep unrelated repository files intact. + +## Apply repository labels when in scope + +Read [references/github.md](references/github.md) when reading or applying live +GitHub configuration. Discover available GitHub tools first; use `gh` if they do +not support the required operation. Verify the account and explicit owner/repo. + +Read all current labels, then create only missing selected labels. Preserve existing +colors and descriptions unless their update is requested; report any conflicts. +Never delete or rename labels, force-sync the manifest, or relabel old issues as +part of an initial setup. If a write fails, inspect live state before retrying; +stop at an authentication/permission boundary rather than looping writes. + +Local forms become active only after they reach the repository's default branch. +Do not claim that local files are already live, or push them without user scope. + +## Verify and report + +- Parse JSON and YAML with an available parser. Check unique label names, six-digit + color strings, nonempty form bodies, unique form field IDs, and required fields. +- Check that form labels exist in the final manifest or verified live label set. + When remote creation is deferred, report those labels as pending dependencies. +- In native-type mode, verify form `type` names against organization configuration + when accessible. Do not claim unverified names are available. +- Inspect the final guide for one clear type source and one priority source. + Check that `needs-info` requires a concrete request and that unknown priority is + allowed. Review the diff for overwrites or repeated artifacts. +- If labels were applied, read them back. A local manifest is not evidence of a + successful GitHub update. Static parsing does not verify the live issue chooser. + +Report the target repository, changed files, selected model, checks actually run, +and live changes separately from pending ones. Make any missing permissions or +default-branch publication requirement explicit without labeling partial setup +complete. Do not create test issues just to validate a form unless requested. diff --git a/skills/plz-setup-issues/agents/openai.yaml b/skills/plz-setup-issues/agents/openai.yaml new file mode 100644 index 0000000..82802bd --- /dev/null +++ b/skills/plz-setup-issues/agents/openai.yaml @@ -0,0 +1,4 @@ +interface: + display_name: "Set Up Repository Issues" + short_description: "Initialize GitHub issue labels, forms, and triage rules" + default_prompt: "Use $plz-setup-issues to set up issue labels, forms, and a triage guide for this repository." diff --git a/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/bug.yml b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/bug.yml new file mode 100644 index 0000000..ef997ca --- /dev/null +++ b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/bug.yml @@ -0,0 +1,41 @@ +name: Bug report +description: Report behavior that differs from what you expected. +labels: + - type:bug + - needs-triage +body: + - type: textarea + id: expected + attributes: + label: Expected behavior + description: What should happen? + validations: + required: true + - type: textarea + id: actual + attributes: + label: Actual behavior + description: What happened instead? Include relevant error messages. + validations: + required: true + - type: textarea + id: reproduction + attributes: + label: Steps to reproduce + description: Include a minimal example or the steps you tried. If reproduction is inconsistent, describe when it happens. + validations: + required: true + - type: textarea + id: environment + attributes: + label: Version and environment + description: Include the release or commit and relevant runtime, operating system, browser, or deployment details. If a detail is unknown, say so. + validations: + required: true + - type: textarea + id: evidence + attributes: + label: Additional evidence + description: Relevant logs, screenshots, frequency, impact, or workarounds. Remove secrets and personal information. + validations: + required: false diff --git a/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/config.yml b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..0086358 --- /dev/null +++ b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/config.yml @@ -0,0 +1 @@ +blank_issues_enabled: true diff --git a/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml new file mode 100644 index 0000000..047f860 --- /dev/null +++ b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml @@ -0,0 +1,33 @@ +name: Feature or improvement request +description: Describe a problem and the behavior that would solve it. +labels: + - type:feature + - needs-triage +body: + - type: textarea + id: problem + attributes: + label: Problem to solve + description: Who encounters this problem, and what are they trying to do? + validations: + required: true + - type: textarea + id: outcome + attributes: + label: Desired outcome + description: Describe the behavior or result that would help. A proposed implementation is optional. + validations: + required: true + - type: textarea + id: alternatives + attributes: + label: Alternatives or current workaround + validations: + required: false + - type: textarea + id: context + attributes: + label: Additional context + description: Examples or constraints that would help evaluate the request. + validations: + required: false diff --git a/skills/plz-setup-issues/assets/labels.json b/skills/plz-setup-issues/assets/labels.json new file mode 100644 index 0000000..132a469 --- /dev/null +++ b/skills/plz-setup-issues/assets/labels.json @@ -0,0 +1,13 @@ +[ + {"name": "type:bug", "color": "D73A4A", "description": "Observed behavior differs from expected behavior"}, + {"name": "type:feature", "color": "A2EEEF", "description": "Add a new capability"}, + {"name": "type:improvement", "color": "84B6EB", "description": "Improve an existing capability"}, + {"name": "type:maintenance", "color": "D4C5F9", "description": "Internal upkeep: refactoring, tests, dependencies, build, or CI"}, + {"name": "type:docs", "color": "0075CA", "description": "Write or update documentation"}, + {"name": "needs-triage", "color": "FBCA04", "description": "Awaiting initial maintainer review"}, + {"name": "needs-info", "color": "D876E3", "description": "Specific information is needed to assess or reproduce this issue"}, + {"name": "priority:P0", "color": "B60205", "description": "Immediate response to ongoing harm or an active critical incident"}, + {"name": "priority:P1", "color": "D93F0B", "description": "Prioritize in the next agreed work cycle"}, + {"name": "priority:P2", "color": "FBCA04", "description": "Schedule through normal planning"}, + {"name": "priority:P3", "color": "C2E0C6", "description": "Defer until capacity allows"} +] diff --git a/skills/plz-setup-issues/references/github.md b/skills/plz-setup-issues/references/github.md new file mode 100644 index 0000000..cbb6901 --- /dev/null +++ b/skills/plz-setup-issues/references/github.md @@ -0,0 +1,69 @@ +# GitHub inspection and label application + +Use an available GitHub integration when it supports the required operation and +account. Otherwise use `gh`. Verify current capabilities and official documentation +if an API, Issue Type, or field feature differs from the examples below. + +## Read before writing + +For CLI use, discover the local remotes and verify the current process identity: + +```sh +git remote -v +gh api user --jq .login +``` + +Use credentials already authorized for the target and any repository account rule. +An owner in a URL does not establish the logged-in identity. Avoid global account +switching. Use an explicit repository on every repository-specific call. These +examples use a placeholder that must be replaced with the resolved target: + +```sh +gh repo view OWNER/REPO --json nameWithOwner,defaultBranchRef,hasIssuesEnabled +gh label list --repo OWNER/REPO --limit 1000 --json name,color,description +``` + +If there are more labels than the chosen limit, paginate the API instead of treating +the truncated list as complete. Inspect organization Issue Types or project fields +only if needed for a real choice. A personal repository does not have organization +Issue Types. Do not create a board or modify organization settings to satisfy a +baseline that can work with repository labels. + +## Add missing labels + +Compare `.github/labels.json` with the complete live label list. Create only names +that are missing, using each manifest entry's actual color and description: + +```sh +gh label create 'needs-triage' --repo OWNER/REPO --color 'FBCA04' --description 'Awaiting initial maintainer review' +``` + +Use structured tool arguments or an argument array such as Python's +`subprocess.run([...], check=True)` for dynamic values, especially translated label +descriptions. Do not interpolate user-provided text into shell code. Do not use +`--force` to reconcile an existing label automatically. An existing label's name, +description, and color may be relied on by other workflows and historical issues. + +Read back the labels after creation. On failure, identify which additions succeeded +before deciding whether a retry is appropriate. Do not switch accounts or request +broader scopes automatically to work around a denied operation. + +## Templates and publication + +Form `labels` only apply labels that actually exist; a local manifest does not +create them. Top-level form `type` must match an available organization Issue Type. +Omit it in label-only mode. Keep YAML field IDs unique and preserve any existing +contact links. Files become active when present on the default branch; local edits +alone do not change the GitHub chooser. + +Never report the live chooser as tested from JSON/YAML parsing alone. If browser +preview or publication is outside scope, say exactly what was verified locally. + +## Official references + +Checked 2026-11-03; consult these for changing GitHub capabilities: + +- [Issue forms](https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms) +- [Organization Issue Types](https://docs.github.com/en/issues/tracking-your-work-with-issues/using-issues/managing-issue-types-in-an-organization) +- [Organization issue fields](https://docs.github.com/en/issues/tracking-your-work-with-issues/using-issues/managing-issue-fields-in-your-organization) +- [Create labels with gh](https://cli.github.com/manual/gh_label_create) diff --git a/skills/plz-setup-issues/references/taxonomy.md b/skills/plz-setup-issues/references/taxonomy.md new file mode 100644 index 0000000..87234f4 --- /dev/null +++ b/skills/plz-setup-issues/references/taxonomy.md @@ -0,0 +1,99 @@ +# Baseline and adaptation + +This is a starter convention, not a standard all mature repositories follow. +Keep the initial vocabulary small and grow it when it answers a real routing, +planning, or reporting question. Keep issue classification distinct from commit +message types: a maintenance issue can produce several kinds of commits. + +## Work type + +Choose one main purpose per issue. Split independently deliverable work when its +owners, priorities, or acceptance criteria differ. + +| Label | Meaning | Example | +| --- | --- | --- | +| `type:bug` | Observed behavior differs from supported, expected behavior | A documented command fails on supported input | +| `type:feature` | Introduces a capability that does not exist | Add an export command | +| `type:improvement` | Improves an existing capability | Make an existing export resumable | +| `type:maintenance` | Internal upkeep such as refactoring, tests, dependencies, build, or CI | Replace a deprecated test runner | +| `type:docs` | The intended deliverable is documentation | Explain export configuration | + +A bug fix may require tests and documentation without changing its main type. +Use acceptance criteria to settle feature/improvement ambiguity; prefer an existing +repository convention over arguing about the boundary. + +GitHub's default organization Issue Types are Bug, Feature, and Task. Reusing them +merges feature/improvement and maintenance/docs respectively. This is a valid, +simpler model. Detailed type labels alongside native types are a deliberate +exception that needs a documented mapping, not an automatic default. + +## Triage and progress + +`needs-triage` means a maintainer has not reviewed the issue. Remove it when the +issue's validity, category, and next action have been assessed. Accepting an issue +does not promise an implementation date or require a priority immediately. + +`needs-info` means a specific missing fact prevents assessment or reproduction. +Add a comment naming the required information and remove the label when supplied. +An issue can need both initial review and information; the labels are independent. +Do not use `needs-info` just because priority or an assignee is unset. + +The guide should describe this small process: + +1. Register the problem and expected outcome. Forms add the initial type and + `needs-triage`; maintainers may use a blank issue for other work types. +2. Review validity, duplicates, scope, and missing information. Confirm or correct + the type and identify the next action. A rotating maintainer or area owner can + do this; do not invent a person or response-time commitment. +3. When planning work, choose a priority and assignee. If a board exists, Ready + means the work is sufficiently understood and selected for an upcoming work + cycle; Backlog can contain valid work that has not been scheduled. +4. Link implementation PRs. Close with a fix reference and relevant verification, + or explain a duplicate, unsupported request, or other closure reason. If a fix + must be checked after release, record the version and verification owner/method. + +Do not add automatic inactivity closure by default. A quiet issue may still be a +valid defect. Establish a review cadence that fits available maintainers instead +of copying a public project's response deadline or vote threshold. + +## Priority + +Priority is a maintainer's scheduling decision informed by actual exposure, +frequency, workarounds, deadlines, and available capacity. Leave it unset until +assessed; do not assign a default P2 to every report or embed priority in titles. + +| Value | Meaning | +| --- | --- | +| P0 | Immediate response to ongoing harm or an active critical incident | +| P1 | Prioritize in the next agreed work cycle | +| P2 | Schedule through normal planning | +| P3 | Defer until capacity allows | + +## Extensions + +- **Area:** add `area:*` only for useful code or product boundaries. Technology + layers and product features are both valid models; pick boundaries that help + route or find work. One main area is a useful default, with more when needed. +- **Impact/Severity:** add for projects where failure consequences affect decisions. + Distinguish damage when triggered from how urgently to act. Define levels for + the project's actual risks rather than importing another product's incidents. +- **Versions/platforms:** collect these in a bug form first; promote them to labels + or fields if maintainers need cross-issue queries or backport coordination. +- **Customers:** add only when customer-specific support is part of the workflow. +- **Community contribution:** add `good first issue` or `help wanted` when the team + is prepared to guide outside contributors; do not equate low priority with easy. + +## Sources and limits + +Reviewed 2026-11-03. These are examples supporting the design, not dependencies: + +- [Kubernetes triage](https://www.kubernetes.dev/docs/guide/issue-triage/): separates + kind, ownership, priority, and initial review. +- [CPython labels](https://devguide.python.org/triage/labels/): adds components, + platforms, and affected versions because those dimensions matter to its work. +- [VS Code tracking](https://github.com/microsoft/vscode/wiki/Issue-Tracking): + separates inbox routing, area ownership, planning, and verification. + +Their large public communities justify conventions and automation that a new +repository may not need. The five-type baseline above is this skill's recommended +starting point, not a claim that these projects share an identical taxonomy. From f24425f8494e79d7d3a036ff86079ed1dbf75ac3 Mon Sep 17 00:00:00 2001 From: codekongdev <349702077+codekongdev@users.noreply.github.com> Date: Tue, 3 Nov 2026 14:26:05 +0900 Subject: [PATCH 2/5] fix: preserve issue setup conventions and redact remotes --- skills/plz-setup-issues/SKILL.md | 20 ++++++++-- skills/plz-setup-issues/references/github.md | 41 +++++++++++++++++++- 2 files changed, 55 insertions(+), 6 deletions(-) diff --git a/skills/plz-setup-issues/SKILL.md b/skills/plz-setup-issues/SKILL.md index 9a9f6e5..6957c31 100644 --- a/skills/plz-setup-issues/SKILL.md +++ b/skills/plz-setup-issues/SKILL.md @@ -83,6 +83,14 @@ Use the prose language already used by the repository unless the user specifies another. Translate form names, field text, label descriptions, and the guide; keep chosen label identifiers stable. The bundled assets are English starting points. +If the target has no local issue templates or chooser configuration, inspect any +defaults in the owner's public `.github` repository before creating local files. +A valid local template or `config.yml` disables the entire inherited +`.github/ISSUE_TEMPLATE/` directory. Carry forward its forms, contact links, and +security-reporting guidance in the local replacement. If inherited defaults cannot +be inspected, report that limitation before publishing the replacement; missing +local files do not prove that no effective templates exist. + 1. Build `.github/labels.json` from [assets/labels.json](assets/labels.json), including only the selected labels. Exclude `type:*` for native-type-only setups and `priority:*` when a Priority field is used. Match existing names when equivalent. @@ -91,11 +99,15 @@ chosen label identifiers stable. The bundled assets are English starting points. [assets/ISSUE_TEMPLATE/feature.yml](assets/ISSUE_TEMPLATE/feature.yml) into the target's `.github/ISSUE_TEMPLATE/`. In native-type mode remove the type label from `labels` and set the form's top-level `type` to the verified organization type name. - Use `needs-triage` in both forms. Do not preassign priority, area, or people. + Use the selected triage label name in both forms (`needs-triage` by default), + matching the manifest and any equivalent existing label selected in step 1. + Do not preassign priority, area, or people. 3. Merge [assets/ISSUE_TEMPLATE/config.yml](assets/ISSUE_TEMPLATE/config.yml) with any - existing chooser config. Keep blank issues enabled by default so maintainers can - file maintenance/docs work without a mismatched form. Preserve contact links and - security-reporting instructions; do not invent a contact destination. + effective existing chooser config, including inherited configuration when + replacing owner-level defaults. Keep blank issues enabled by default so + maintainers can file maintenance/docs work without a mismatched form. Preserve + contact links and security-reporting instructions; do not invent a contact + destination. 4. Write or update `.github/ISSUE_TRIAGE.md` with the selected definitions, type and priority storage, what each form collects, and the review/close procedure from the taxonomy reference. Document actual choices, not unused alternatives. diff --git a/skills/plz-setup-issues/references/github.md b/skills/plz-setup-issues/references/github.md index cbb6901..a4cba8e 100644 --- a/skills/plz-setup-issues/references/github.md +++ b/skills/plz-setup-issues/references/github.md @@ -6,10 +6,46 @@ if an API, Issue Type, or field feature differs from the examples below. ## Read before writing -For CLI use, discover the local remotes and verify the current process identity: +For CLI use, inspect remote destinations without returning raw URLs to the agent +or logs: URLs can contain credentials. This local example captures Git output, +returns only the host and repository path, and omits unrecognized destinations. +It makes no network requests. Do not enable shell tracing or print the captured +output while adapting it. + +```sh +python3 - <<'PY' +import json +import re +import subprocess +from urllib.parse import urlsplit + +result = subprocess.run(["git", "remote", "-v"], capture_output=True, + text=True, errors="replace") +if result.returncode: + raise SystemExit("Cannot inspect remotes; raw Git output suppressed.") +for line in result.stdout.splitlines(): + fields = line.split() + if len(fields) != 3: + print("[unrecognized remote omitted]") + continue + raw = fields[1] + scp = re.fullmatch(r"(?:[^/@:\s]+@)?(\[[0-9a-fA-F:]+\]|[^/@:\s]+):([^:\s]+)", raw) + if "://" not in raw and scp: + raw = "ssh://" + scp[1] + "/" + scp[2] + try: + url = urlsplit(raw) + if url.scheme not in {"http", "https", "ssh", "git"} or not url.hostname: + raise ValueError + print(json.dumps({"host": url.hostname, "path": url.path})) + except ValueError: + print("[unrecognized remote omitted]") +PY +``` + +Verify the current process identity with the credentials intended for subsequent +GitHub operations: ```sh -git remote -v gh api user --jq .login ``` @@ -64,6 +100,7 @@ preview or publication is outside scope, say exactly what was verified locally. Checked 2026-11-03; consult these for changing GitHub capabilities: - [Issue forms](https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms) +- [Default community health files and inherited templates](https://docs.github.com/en/communities/setting-up-your-project-for-healthy-contributions/creating-a-default-community-health-file) - [Organization Issue Types](https://docs.github.com/en/issues/tracking-your-work-with-issues/using-issues/managing-issue-types-in-an-organization) - [Organization issue fields](https://docs.github.com/en/issues/tracking-your-work-with-issues/using-issues/managing-issue-fields-in-your-organization) - [Create labels with gh](https://cli.github.com/manual/gh_label_create) From 805bd98c1eade638a4432fec76c827a9a16b7063 Mon Sep 17 00:00:00 2001 From: codekongdev <349702077+codekongdev@users.noreply.github.com> Date: Tue, 3 Nov 2026 14:33:27 +0900 Subject: [PATCH 3/5] fix: inspect internal issue template defaults --- skills/plz-setup-issues/SKILL.md | 6 ++++-- skills/plz-setup-issues/references/github.md | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/skills/plz-setup-issues/SKILL.md b/skills/plz-setup-issues/SKILL.md index 6957c31..bf7c99a 100644 --- a/skills/plz-setup-issues/SKILL.md +++ b/skills/plz-setup-issues/SKILL.md @@ -83,8 +83,10 @@ Use the prose language already used by the repository unless the user specifies another. Translate form names, field text, label descriptions, and the guide; keep chosen label identifiers stable. The bundled assets are English starting points. -If the target has no local issue templates or chooser configuration, inspect any -defaults in the owner's public `.github` repository before creating local files. +If the target has no local issue templates or chooser configuration, inspect the +effective owner-level `.github` repository before creating local files. This +repository is internal for organizations with managed users and public for other +eligible accounts. A valid local template or `config.yml` disables the entire inherited `.github/ISSUE_TEMPLATE/` directory. Carry forward its forms, contact links, and security-reporting guidance in the local replacement. If inherited defaults cannot diff --git a/skills/plz-setup-issues/references/github.md b/skills/plz-setup-issues/references/github.md index a4cba8e..4eccee7 100644 --- a/skills/plz-setup-issues/references/github.md +++ b/skills/plz-setup-issues/references/github.md @@ -100,7 +100,7 @@ preview or publication is outside scope, say exactly what was verified locally. Checked 2026-11-03; consult these for changing GitHub capabilities: - [Issue forms](https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms) -- [Default community health files and inherited templates](https://docs.github.com/en/communities/setting-up-your-project-for-healthy-contributions/creating-a-default-community-health-file) +- [Default community health files and inherited templates](https://docs.github.com/en/enterprise-cloud@latest/communities/setting-up-your-project-for-healthy-contributions/creating-a-default-community-health-file) - [Organization Issue Types](https://docs.github.com/en/issues/tracking-your-work-with-issues/using-issues/managing-issue-types-in-an-organization) - [Organization issue fields](https://docs.github.com/en/issues/tracking-your-work-with-issues/using-issues/managing-issue-fields-in-your-organization) - [Create labels with gh](https://cli.github.com/manual/gh_label_create) From 26407d03a553d2783ec0d676d701e2e740fbe9aa Mon Sep 17 00:00:00 2001 From: codekongdev <349702077+codekongdev@users.noreply.github.com> Date: Tue, 3 Nov 2026 14:43:39 +0900 Subject: [PATCH 4/5] fix: apply selected issue type labels to forms --- skills/plz-setup-issues/SKILL.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/skills/plz-setup-issues/SKILL.md b/skills/plz-setup-issues/SKILL.md index bf7c99a..9667a15 100644 --- a/skills/plz-setup-issues/SKILL.md +++ b/skills/plz-setup-issues/SKILL.md @@ -99,10 +99,11 @@ local files do not prove that no effective templates exist. This file is a desired-label manifest, not an automatic synchronization service. 2. Adapt [assets/ISSUE_TEMPLATE/bug.yml](assets/ISSUE_TEMPLATE/bug.yml) and [assets/ISSUE_TEMPLATE/feature.yml](assets/ISSUE_TEMPLATE/feature.yml) into the - target's `.github/ISSUE_TEMPLATE/`. In native-type mode remove the type label from - `labels` and set the form's top-level `type` to the verified organization type name. - Use the selected triage label name in both forms (`needs-triage` by default), - matching the manifest and any equivalent existing label selected in step 1. + target's `.github/ISSUE_TEMPLATE/`. Map every form label to the name selected in + step 1, including work-type labels and the triage label (`needs-triage` by default), + so both forms match the manifest when reusing equivalent existing names. + When using native Issue Types, set each form's top-level `type` to its verified + organization type name. In native-type-only mode, omit work-type labels. Do not preassign priority, area, or people. 3. Merge [assets/ISSUE_TEMPLATE/config.yml](assets/ISSUE_TEMPLATE/config.yml) with any effective existing chooser config, including inherited configuration when From 0305c2780f77f6bf4a69800083b1ec0905090e86 Mon Sep 17 00:00:00 2001 From: codekongdev <349702077+codekongdev@users.noreply.github.com> Date: Tue, 3 Nov 2026 14:53:05 +0900 Subject: [PATCH 5/5] fix: keep feature forms aligned with issue types --- skills/plz-setup-issues/SKILL.md | 2 ++ skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/skills/plz-setup-issues/SKILL.md b/skills/plz-setup-issues/SKILL.md index 9667a15..75daf24 100644 --- a/skills/plz-setup-issues/SKILL.md +++ b/skills/plz-setup-issues/SKILL.md @@ -104,6 +104,8 @@ local files do not prove that no effective templates exist. so both forms match the manifest when reusing equivalent existing names. When using native Issue Types, set each form's top-level `type` to its verified organization type name. In native-type-only mode, omit work-type labels. + Keep the feature form for new capabilities. Route improvements to blank issues, + with maintainers assigning the selected work type during triage. Do not preassign priority, area, or people. 3. Merge [assets/ISSUE_TEMPLATE/config.yml](assets/ISSUE_TEMPLATE/config.yml) with any effective existing chooser config, including inherited configuration when diff --git a/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml index 047f860..e1eeb93 100644 --- a/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml +++ b/skills/plz-setup-issues/assets/ISSUE_TEMPLATE/feature.yml @@ -1,5 +1,5 @@ -name: Feature or improvement request -description: Describe a problem and the behavior that would solve it. +name: Feature request +description: Request a new capability. For improvements to existing behavior, use a blank issue. labels: - type:feature - needs-triage