Community Health
GitHub’s Community Standards checklist expects every public repo to ship a minimum set of community-health files. This skill provides the canonical templates and the placement rules. All templates live in assets/ and mirror the target repo layout.
Files and Placement
Copy each asset to the target repo path shown below. Sources are relative to this skill’s assets/ directory.
| Asset source | Target path | Purpose |
|---|---|---|
CODE_OF_CONDUCT.md | CODE_OF_CONDUCT.md | Contributor Covenant 2.1; populates community profile. |
SECURITY.md | SECURITY.md | Private vulnerability reporting; populates the Security tab. |
github/pull_request_template.md | .github/pull_request_template.md | Single PR template used for every PR. |
github/ISSUE_TEMPLATE/bug_report.yml | .github/ISSUE_TEMPLATE/bug_report.yml | Structured bug report form. |
github/ISSUE_TEMPLATE/feature_request.yml | .github/ISSUE_TEMPLATE/feature_request.yml | Structured feature request form. |
github/ISSUE_TEMPLATE/config.yml | .github/ISSUE_TEMPLATE/config.yml | Disables blank issues; adds Security + Discussions contact links. |
LICENSE and CONTRIBUTING.md also show on the community profile but are owned by scaffold-project and the language-specific scaffold skills, not here.
Template Placeholders
Templates contain {PLACEHOLDER} tokens that must be replaced when copied into a target repo.
| Placeholder | Source | Example |
|---|---|---|
{OWNER} | GitHub owner (user or org) from the remote URL or gh repo view --json owner | urmzd |
{REPO} | Repo name on GitHub (without owner) | sr, teasr, saige |
{CURRENT_MAJOR} | Current major version from the project manifest (Cargo.toml, pyproject.toml, package.json, etc.). Use 0 for pre-1.0 projects and adjust the supported-versions table accordingly. | 6, 1, 0 |
{CHECK_COMMAND} | The quality-gate command from the project’s task runner | just check, npm run ci, cargo test --workspace, go test ./... |
Always replace every placeholder. Leaving {OWNER}, {REPO}, or {CURRENT_MAJOR} unrendered in a shipped file is a bug.
Contact
All community-health templates reference $COMMUNITY_HEALTH_CONTACT (falling back to git config user.email) as the private contact. Set the env var before scaffolding.
Usage
New repo (invoked by scaffold-project / repo-init)
- Copy
assets/CODE_OF_CONDUCT.mdto the repo root (no edits needed). - Copy
assets/SECURITY.md, substituting{OWNER},{REPO}, and{CURRENT_MAJOR}. For pre-1.0 projects, rewrite the table to0.x Yes / < 0.x No. - Copy
assets/github/pull_request_template.mdto.github/pull_request_template.md, substituting{CHECK_COMMAND}. Append language-specific verification checks if the scaffold skill defines them (e.g.cargo clippy -- -D warnings). - Copy the three
assets/github/ISSUE_TEMPLATE/*files to.github/ISSUE_TEMPLATE/, substituting{OWNER}and{REPO}inconfig.yml.
Backfill an existing repo
- Run the
check-projectskill to identify which community-health files are missing. - Copy only the missing files from
assets/. - Do not overwrite an existing SECURITY.md that already has a project-specific Scope or Supply Chain section. Merge instead.
Audit
Use check-project to verify the six files exist at the expected paths, placeholders are fully rendered, and the PR-template {CHECK_COMMAND} matches the project’s actual quality-gate command.
Rules
- No auto-overwrite. If a target file already exists and has been customized (e.g. a SECURITY.md with a project-specific Scope section), diff-merge rather than overwrite.
- Email comes from one source. Resolve from
$COMMUNITY_HEALTH_CONTACT, falling back togit config user.email. Do not silently substitute a different value mid-scaffold. - Placeholders are mandatory. A shipped template with
{OWNER},{REPO}, or{CURRENT_MAJOR}unrendered is a FAIL incheck-project. - One PR template. Use the single
.github/pull_request_template.mdfile. Do not add per-branch or per-type templates unless the project explicitly needs them. - Issue forms over markdown. Use the
.ymlissue-form schema, not legacy.mdissue templates.