Skip to content

feat(scanner): discover GitHub Copilot instruction Markdown files - #3

Merged
mockingbird777 merged 1 commit into
mockingbird777:mainfrom
dchaudhari7177:feat/copilot-instructions
Jul 20, 2026
Merged

feat(scanner): discover GitHub Copilot instruction Markdown files#3
mockingbird777 merged 1 commit into
mockingbird777:mainfrom
dchaudhari7177:feat/copilot-instructions

Conversation

@dchaudhari7177

Copy link
Copy Markdown
Contributor

What

Recognizes the GitHub Copilot instruction conventions as prompt resources:

  • copilot-instructions.md (exact, case-insensitive — tested with COPILOT-INSTRUCTIONS.MD)
  • *.instructions.md (suffix, case-insensitive)

Both flow through the existing frontmatter/heading/description/stable-ID/corpus pipeline unchanged — the diff is one extra branch in markdownKind plus instructions in the fallback-name suffix strip (so security.instructions.md names as security, matching how .prompt.md behaves). No remote lookup, no new dependency.

Ordinary Markdown (README.md, notes.md) stays out of the catalog, and .github/ was already walked (only .git/node_modules/dist/coverage/.task2tool are ignored).

Tests

New scanner test covering nested .github/copilot-instructions.md, .github/instructions/security.instructions.md (frontmatter name/tags respected, prompt: ID), the uppercase form, README/notes exclusion, and deterministic ordering across two scans.

npm test: 27/29 — the two failures (symbolic links, npm-style binary symlink) are pre-existing on my Windows machine (symlink creation needs elevation) and fail identically on a clean checkout.

README discovery table updated.

Fixes #2

Recognize copilot-instructions.md and *.instructions.md (case-insensitive)
and classify them as prompt resources through the existing frontmatter,
heading, description, stable-ID, and corpus pipeline. Ordinary Markdown
like README.md stays out of the catalog. The fallback-name regex also
strips the .instructions suffix so names stay clean.

Fixes mockingbird777#2
@mockingbird777
mockingbird777 merged commit 4346c39 into mockingbird777:main Jul 20, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants