Skip to content

Add comprehensive Copilot instruction documentation and navigation#241

Merged
rezwana-karim merged 5 commits intomainfrom
copilot/set-up-copilot-instructions
Feb 14, 2026
Merged

Add comprehensive Copilot instruction documentation and navigation#241
rezwana-karim merged 5 commits intomainfrom
copilot/set-up-copilot-instructions

Conversation

Copy link
Contributor

Copilot AI commented Feb 14, 2026

✅ Set up Copilot Instructions - Review Fixes Applied

Summary

Addressed all 7 PR review comments from copilot-pull-request-reviewer.

Changes Made

1. Fixed Agent Count (25, not 26)

Files Updated:

  • .github/README.md - Updated directory structure and Custom Agents section
  • .github/copilot-instructions.md - Updated Custom Agents count
  • .github/COPILOT_SETUP_SUMMARY.md - Updated 3 occurrences of agent count

Root Cause: There are 25 agent files (24 .agent.md files + 1 ui-ux-saas-specialist-agent.md), not 26.

Verified Count:

$ ls .github/agents/*.md | wc -l
25

2. Updated RESEND_API_KEY Guidance

Files Updated:

  • .github/COPILOT_QUICKSTART.md

Changes:

  • Environment Configuration Section: Changed from "CRITICAL: Build will fail" to "Note: Build succeeds without RESEND_API_KEY. When missing, magic links are logged to console."
  • Troubleshooting Section: Updated from "Build fails with 'Cannot find module resend'" to "Auth email sending is disabled and magic links are logged to console"

Root Cause: The code now uses lazy initialization (getResend()) which logs magic links to console when RESEND_API_KEY is missing, rather than failing at build time.

Evidence: src/lib/auth.ts lines 14-26 show lazy initialization with console warning when API key is not set.

3. Fixed applyTo Pattern for nodejs-javascript-vitest.instructions.md

File Updated:

  • .github/README.md

Change:

- Applies to: `**.ts, **.js, **.mjs, **.cjs`
+ Applies to: `**/*.js, **/*.mjs, **/*.cjs`

Root Cause: Copied exact pattern from instruction file frontmatter to match actual behavior.

Evidence: .github/instructions/nodejs-javascript-vitest.instructions.md line 3 shows applyTo: '**/*.js, **/*.mjs, **/*.cjs'

4. Fixed Placeholder Issue Number

File Updated:

  • .github/COPILOT_SETUP_SUMMARY.md

Change:

- **Issue:** #[Issue Number] - ✨ Set up Copilot instructions
+ **Issue:** #240 - ✨ Set up Copilot instructions

Review Comments Addressed

✅ Comment 2807821298 (README.md:52)

Fixed applyTo pattern to match instruction file frontmatter exactly.

✅ Comment 2807821310 (COPILOT_QUICKSTART.md:26-30)

Updated guidance to reflect lazy initialization - build succeeds without key, emails logged instead.

✅ Comment 2807821313 (COPILOT_QUICKSTART.md:199-200)

Updated troubleshooting to reflect actual runtime behavior when RESEND_API_KEY is unset.

✅ Comment 2807821318 (COPILOT_SETUP_SUMMARY.md:4)

Replaced placeholder with actual issue number #240.

✅ Comment 2807821323 (COPILOT_SETUP_SUMMARY.md:42)

Corrected agent count from 26 to 25.

✅ Comment 2807821328 (copilot-instructions.md:284-291)

Corrected agent count from 26 to 25.

✅ Comment 2807821331 (README.md:11)

Corrected agent count from 26 to 25 in directory structure.

Verification

Agent Count Verification

$ cd .github/agents && ls -1 *.md
Planer.agent.md
agentic-workflows.agent.md
custom-agent-foundry.agent.md
expert-nextjs-developer.agent.md
expert-react-frontend-engineer.agent.md
github-actions-expert.agent.md
implementation-plan.agent.md
playwright-tester.agent.md
postgresql-dba.agent.md
prd.agent.md
research-technical-spike.agent.md
se-gitops-ci-specialist.agent.md
se-product-manager-advisor.agent.md
se-responsible-ai-code.agent.md
se-security-reviewer.agent.md
se-system-architecture-reviewer.agent.md
se-technical-writer.agent.md
task-planner.agent.md
task-researcher.agent.md
tdd-green.agent.md
tdd-red.agent.md
tdd-refactor.agent.md
typescript-mcp-expert.agent.md
ui-ux-saas-specialist-agent.md
web-design-guidelines-agent.agent.md
Total: 25 files

RESEND_API_KEY Behavior Verification

From src/lib/auth.ts:

// Lines 14-26: Lazy initialization
const getResend = (): Resend | null => {
  if (!resendClient) {
    const apiKey = process.env.RESEND_API_KEY;
    if (!apiKey) {
      console.warn('[auth] RESEND_API_KEY not set. Email verification will be logged to console.');
      return null;
    }
    resendClient = new Resend(apiKey);
  }
  return resendClient;
};

// Lines 42-48: Usage in email provider
const resendInstance = getResend();
if (!resendInstance) {
  console.warn(`[auth] RESEND_API_KEY not set. Dev magic link for ${identifier}: ${url}`);
  return;
}

File Changes Summary

.github/COPILOT_QUICKSTART.md    |  8 ++++----
.github/COPILOT_SETUP_SUMMARY.md | 10 +++++-----
.github/README.md                |  6 +++---
.github/copilot-instructions.md  |  2 +-
4 files changed, 13 insertions(+), 13 deletions(-)

Status

✅ All 7 PR review comments addressed
✅ All changes verified
✅ Documentation accuracy restored
✅ Ready for merge

Original prompt

This section details on the original issue you should resolve

<issue_title>✨ Set up Copilot instructions</issue_title>
<issue_description>Configure instructions for this repository as documented in Best practices for Copilot coding agent in your repository.

</issue_description>

<agent_instructions>Perform comprehensive online research for all the github documentations for proper guidelines also Review the whole repository and all the available sub-agents and all automation supports (along with skills, instructions, prompts) and make sure to use MCP best practice fetch for Next.js 16 and shadcn patterns and for bowser automation testing playwright
</agent_instructions>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@vercel
Copy link

vercel bot commented Feb 14, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
stormcomui Ready Ready Preview, Comment Feb 14, 2026 7:40pm

Copilot AI and others added 3 commits February 14, 2026 19:11
Co-authored-by: rezwana-karim <126201034+rezwana-karim@users.noreply.github.com>
Co-authored-by: rezwana-karim <126201034+rezwana-karim@users.noreply.github.com>
Co-authored-by: rezwana-karim <126201034+rezwana-karim@users.noreply.github.com>
Copilot AI changed the title [WIP] Set up Copilot instructions for repository Add comprehensive Copilot instruction documentation and navigation Feb 14, 2026
Copilot AI requested a review from rezwana-karim February 14, 2026 19:16
@rezwana-karim rezwana-karim marked this pull request as ready for review February 14, 2026 19:17
Copilot AI review requested due to automatic review settings February 14, 2026 19:17
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds missing navigation and onboarding documentation for the repository’s existing Copilot instruction system (repo-wide + path-specific instructions, custom agents, prompts, skills) and documents MCP-first usage patterns.

Changes:

  • Added .github/README.md, .github/COPILOT_QUICKSTART.md, and .github/COPILOT_SETUP_SUMMARY.md to document and index the Copilot instruction system and MCP workflows.
  • Extended .github/copilot-instructions.md with an instruction-system overview, MCP best practices, and Playwright MCP usage notes.
  • Updated .github/agents/AGENTS_INDEX.json to include additional agents in the catalog.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
.github/copilot-instructions.md Adds instruction system overview + MCP/Playwright guidance and cross-references.
.github/agents/AGENTS_INDEX.json Extends the agent catalog entries.
.github/README.md New index/navigator for instructions, agents, prompts, skills, and MCP servers.
.github/COPILOT_SETUP_SUMMARY.md New implementation/maintenance summary of the instruction setup.
.github/COPILOT_QUICKSTART.md New developer/agent onboarding quickstart and troubleshooting guide.

- **`typescript-mcp-server.instructions.md`** - MCP server development with TypeScript
- Applies to: `**/*.ts, **/*.js, **/package.json`
- **`nodejs-javascript-vitest.instructions.md`** - Node.js with Vitest testing
- Applies to: `**.ts, **.js, **.mjs, **.cjs`
Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The listed applyTo patterns for nodejs-javascript-vitest.instructions.md don’t match the instruction file frontmatter (it applies to **/*.js, **/*.mjs, **/*.cjs, not **.ts, **.js, ...). Please copy the exact applyTo glob(s) from the instruction file to avoid misleading readers.

Suggested change
- Applies to: `**.ts, **.js, **.mjs, **.cjs`
- Applies to: `**/*.js, **/*.mjs, **/*.cjs`

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in c3b23e6. Updated to match exact applyTo pattern from instruction file frontmatter: **/*.js, **/*.mjs, **/*.cjs

Comment on lines 26 to 30
RESEND_API_KEY="re_dummy_key_for_build" # Required even for build!
```

**⚠️ CRITICAL:** Build will fail without `RESEND_API_KEY` even with a dummy value.

Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This guide says the build will fail without RESEND_API_KEY, but src/lib/auth.ts now uses lazy initialization and logs a dev magic link when the key is missing. Update this guidance to reflect the current behavior (build should succeed; email sending is disabled/logged).

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in c3b23e6. Updated guidance to reflect lazy initialization behavior - build succeeds without the key, and magic links are logged to console instead of being emailed.

Comment on lines 199 to 200
**Error:** Build fails with "Cannot find module 'resend'"
**Fix:** Add `RESEND_API_KEY="re_dummy_key_for_build"` to `.env.local`
Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

“Missing RESEND_API_KEY” troubleshooting currently says the build fails with "Cannot find module 'resend'", but that error indicates a dependency resolution issue, not a missing API key. Consider updating the error text to match the actual runtime warning/log behavior when RESEND_API_KEY is unset.

Suggested change
**Error:** Build fails with "Cannot find module 'resend'"
**Fix:** Add `RESEND_API_KEY="re_dummy_key_for_build"` to `.env.local`
**Behavior:** Auth email sending is disabled and magic links are logged to the console because `RESEND_API_KEY` is not set
**Fix:** Add `RESEND_API_KEY="re_dummy_key_for_build"` to `.env.local` (a dummy value is fine for local development)

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in c3b23e6. Updated troubleshooting to describe actual runtime behavior: "Auth email sending is disabled and magic links are logged to the console because RESEND_API_KEY is not set"

# Copilot Instructions Setup - Implementation Summary

**Date:** February 14, 2026
**Issue:** #[Issue Number] - ✨ Set up Copilot instructions
Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line still contains a placeholder issue reference (#[Issue Number]). Replace it with the actual issue number (per PR description: #240) or remove the issue line if it’s meant to be a reusable template.

Suggested change
**Issue:** #[Issue Number] - ✨ Set up Copilot instructions
**Issue:** #240 - ✨ Set up Copilot instructions

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in c3b23e6. Replaced placeholder with actual issue number #240.

#### Updated Configuration (1)
4. **`.github/agents/AGENTS_INDEX.json`** (Updated)
- Added 3 missing agents (Planer, agentic-workflows, web-design-guidelines-agent)
- Now includes all 26 custom agents
Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This section claims AGENTS_INDEX.json now includes “all 26 custom agents”, but there are currently 25 .agent.md files under .github/agents/. Update the stated total (or add the missing agent entry/file) so the summary matches the repo.

Suggested change
- Now includes all 26 custom agents
- Now includes all 25 custom agents

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in c3b23e6. Corrected count to 25 agents (verified with ls .github/agents/*.md | wc -l).

Comment on lines 284 to 291
### Custom Agents (26 available)
- **Planning**: Planer, task-planner, task-researcher, implementation-plan
- **Development**: expert-nextjs-developer, expert-react-frontend-engineer, typescript-mcp-expert
- **Testing**: playwright-tester, tdd-red, tdd-green, tdd-refactor
- **Quality**: se-security-reviewer, se-system-architecture-reviewer, web-design-guidelines-agent
- **DevOps**: se-gitops-ci-specialist, github-actions-expert, postgresql-dba

See `.github/agents/` for all available agents.
Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The doc says “Custom Agents (26 available)”, but .github/agents/ currently contains 25 .agent.md files. Please update the stated count (or add the missing agent) so the repository-wide instructions stay accurate.

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in c3b23e6. Corrected count to 25 agents to match actual files in .github/agents/.

.github/
├── copilot-instructions.md # Repository-wide instructions
├── instructions/ # Path-specific instructions (18 files)
├── agents/ # Custom agent definitions (26 agents)
Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Directory structure claims “Custom agent definitions (26 agents)”, but there are currently 25 .agent.md files in .github/agents/. Adjust the count (or add the missing agent) to keep this index accurate.

Suggested change
├── agents/ # Custom agent definitions (26 agents)
├── agents/ # Custom agent definitions (25 agents)

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in c3b23e6. Updated directory structure to show 25 agents.

@rezwana-karim
Copy link
Collaborator

@copilot apply changes based on the comments in this thread

…EY guidance, fix applyTo pattern

Co-authored-by: rezwana-karim <126201034+rezwana-karim@users.noreply.github.com>
@rezwana-karim rezwana-karim merged commit c629af1 into main Feb 14, 2026
2 of 3 checks passed
@rezwana-karim rezwana-karim deleted the copilot/set-up-copilot-instructions branch February 14, 2026 19:40
@github-project-automation github-project-automation bot moved this from Backlog to Done in StormCom Feb 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

✨ Set up Copilot instructions

2 participants