Skip to content

feat(installer): add command and prompt file installation support#58

Merged
rjmurillo merged 8 commits into
mainfrom
feat/pr-comment-responder-command
Dec 18, 2025
Merged

feat(installer): add command and prompt file installation support#58
rjmurillo merged 8 commits into
mainfrom
feat/pr-comment-responder-command

Conversation

@rjmurillo-bot

Copy link
Copy Markdown
Collaborator

Summary

  • Add Claude command installation support - copies pr-comment-responder.md to $HOME/.claude/commands (global) or .claude/commands (repo scope)
  • Add VSCode/Copilot prompt file installation - copies .agent.md files as .prompt.md alongside the agent files

Changes

Configuration (Config.psd1)

  • Added CommandsDir and CommandFiles for Claude Global and Repo scopes
  • Added PromptFiles for Copilot and VSCode Global and Repo scopes

Module (Install-Common.psm1)

  • Added Install-CommandFiles function for Claude slash commands
  • Added Install-PromptFiles function with .agent.md.prompt.md name transformation
  • Updated Get-InstallConfig to return new configuration fields
  • Exported both new functions

Installer (install.ps1)

  • Integrated command file installation for Claude environments
  • Integrated prompt file installation for VSCode/Copilot environments
  • Added appropriate status messages and statistics output

Tests

  • Added 6 tests for Claude CommandsDir/CommandFiles configuration
  • Added 8 tests for Copilot/VSCode PromptFiles configuration
  • Added 14 tests for Install-CommandFiles function
  • Added 9 tests for Install-PromptFiles function
  • Added 8 tests for installer integration
  • All 189 tests pass

Test plan

  • Run Pester tests (Invoke-Pester)
  • Test Claude global installer - verified command file installed
  • Test VSCode global installer - verified both .agent.md and .prompt.md files installed

🤖 Generated with Claude Code

rjmurillo-bot and others added 2 commits December 17, 2025 21:36
Add ability to install agent files as Claude slash commands in addition
to the agents directory. This enables pr-comment-responder.md to be
invoked as /pr-comment-responder in Claude Code.

Changes:
- Config.psd1: Add CommandsDir and CommandFiles configuration for Claude
  Global ($HOME/.claude/commands) and Repo (.claude/commands) scopes
- Install-Common.psm1: Add Install-CommandFiles function to copy
  specified agent files to the commands directory
- install.ps1: Integrate command installation after agent files

Test coverage:
- Config.Tests.ps1: 6 new tests for command configuration
- Install-Common.Tests.ps1: 14 new tests for Install-CommandFiles and
  Get-InstallConfig command field validation
- install.Tests.ps1: 4 new tests for command installation integration

All 168 tests pass.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add ability to install agent files as prompt files alongside agents.
This copies pr-comment-responder.agent.md as pr-comment-responder.prompt.md
in the same destination directory for VSCode and Copilot environments.

Changes:
- Config.psd1: Add PromptFiles configuration for Copilot and VSCode
  (Global and Repo scopes)
- Install-Common.psm1: Add Install-PromptFiles function that copies
  agent files with .agent.md → .prompt.md name transformation
- install.ps1: Integrate prompt file installation after agent files

Test coverage:
- Config.Tests.ps1: 8 new tests for PromptFiles configuration
- Install-Common.Tests.ps1: 9 new tests for Install-PromptFiles function
  and Get-InstallConfig PromptFiles validation
- install.Tests.ps1: 4 new tests for prompt installation integration

All 189 tests pass.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@rjmurillo rjmurillo self-requested a review December 18, 2025 05:45
rjmurillo-bot and others added 5 commits December 17, 2025 21:49
Add explicit guidance that the session protocol is mandatory even for:
- Resumed/continued conversations after context summarization
- Quick tasks (protocol overhead is minimal)
- Instructions saying "continue without asking questions"

Include minimum session checklist (START/END) with link to full
protocol in AGENTS.md.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…essions

Add explicit guidance that the session protocol is mandatory even for:
- Resumed/continued conversations after context summarization
- Quick tasks (protocol overhead is minimal)
- Instructions saying "continue without asking questions"

Include minimum session checklist (START/END) with link to full
protocol in AGENTS.md.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Update installation documentation for all three platforms:

- VS Code: document prompt files (*.prompt.md) installed alongside agents
- Copilot CLI: document prompt files (*.prompt.md) installed alongside agents
- Claude: document slash commands installed to commands/ directory

Each platform section now includes a "File Types" subsection explaining
what gets installed and where.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Update end-user installation documentation:

- Add Commands/Prompts column to installation paths tables
- Add "What Gets Installed" section explaining file types per platform
- Update uninstallation commands to include commands directory
- Update commit examples to include all relevant paths

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Auto-fix from markdownlint-cli2:
- Add blank lines before code blocks
- Add blank lines before lists

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Dec 18, 2025

Copy link
Copy Markdown

Warning

Rate limit exceeded

@rjmurillo-bot has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 8 minutes and 22 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between 41ef2bd and fab2d5d.

📒 Files selected for processing (13)
  • .github/copilot-instructions.md (1 hunks)
  • .github/instructions/agent-prompts.instructions.md (2 hunks)
  • .github/instructions/security.instructions.md (2 hunks)
  • .github/instructions/testing.instructions.md (2 hunks)
  • AGENTS.md (3 hunks)
  • CLAUDE.md (1 hunks)
  • docs/installation.md (5 hunks)
  • scripts/install.ps1 (1 hunks)
  • scripts/lib/Config.psd1 (3 hunks)
  • scripts/lib/Install-Common.psm1 (3 hunks)
  • scripts/tests/Config.Tests.ps1 (6 hunks)
  • scripts/tests/Install-Common.Tests.ps1 (4 hunks)
  • scripts/tests/install.Tests.ps1 (1 hunks)
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/pr-comment-responder-command

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai

coderabbitai Bot commented Dec 18, 2025

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

Extends the installation system to handle Claude commands and prompt files across platforms. Updates configuration to track new artifact types. Adds session protocol documentation to GitHub Copilot and Claude instructions. Updates installation documentation and paths for the new file types.

Changes

Cohort / File(s) Summary
Documentation updates
.github/copilot-instructions.md, CLAUDE.md, AGENTS.md, docs/installation.md
Added mandatory session protocol sections; expanded AGENTS.md file-type patterns for Claude, VS Code, and Copilot CLI; restructured installation paths tables to separate Agents from Commands/Prompts columns; added "What Gets Installed" reference section.
Instruction formatting and security guidance
.github/instructions/agent-prompts.instructions.md, .github/instructions/security.instructions.md, .github/instructions/testing.instructions.md
Minor formatting (blank lines after headings); expanded OWASP focus areas; added File Path Triggers block for security-sensitive paths; expanded threat modeling with STRIDE categories; added code coverage and mock testing principles.
Configuration schema
scripts/lib/Config.psd1
Added CommandsDir and CommandFiles keys to Claude global and repo scopes; added PromptFiles arrays to Copilot and VSCode global and repo scopes.
Installation functions
scripts/lib/Install-Common.psm1
Added Install-CommandFiles and Install-PromptFiles public functions; updated Get-InstallConfig to expose CommandsDir, CommandFiles, and PromptFiles fields.
Installation orchestration
scripts/install.ps1
Integrated conditional calls to Install-CommandFiles (when configured) and Install-PromptFiles (when configured); reports installed/updated/skipped counts.
Test coverage
scripts/tests/Config.Tests.ps1, scripts/tests/Install-Common.Tests.ps1, scripts/tests/install.Tests.ps1
Added validation for new config keys (CommandsDir, CommandFiles, PromptFiles) across all scopes; added test suites for Install-CommandFiles and Install-PromptFiles with directory creation, file transformation, force-update, and error handling scenarios; added script-level tests for command and prompt installation paths.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~35 minutes

  • Config.psd1: verify key naming consistency across all three platforms and scopes
  • Install-Common.psm1: review error handling in new file installation functions; confirm status hashtable (Installed/Updated/Skipped) is correctly populated
  • install.ps1: ensure conditional logic properly gates command and prompt installation based on config presence
  • Documentation accuracy: cross-check AGENTS.md file-type patterns and installation paths against actual Config.psd1 structure
  • Test coverage: confirm new functions cover missing files, existing files with -Force, and directory creation edge cases

Possibly related PRs

  • PR #41: Extends unified installer by modifying the same installation modules (Config.psd1, Install-Common.psm1, install.ps1) to add command and prompt file support.
  • PR #46: Modifies CLAUDE.md, AGENTS.md, and Copilot instructions to add/strengthen mandatory session and handoff protocol documentation.

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed Title follows conventional commit format (feat type with scope and subject) and clearly describes the main change: adding command and prompt file installation support.
Description check ✅ Passed Description directly relates to the changeset, detailing configuration changes, module updates, installer integration, and test coverage that match the file modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/pr-comment-responder-command

📜 Recent review details

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 41ef2bd and db5255a.

📒 Files selected for processing (13)
  • .github/copilot-instructions.md (1 hunks)
  • .github/instructions/agent-prompts.instructions.md (2 hunks)
  • .github/instructions/security.instructions.md (2 hunks)
  • .github/instructions/testing.instructions.md (2 hunks)
  • AGENTS.md (3 hunks)
  • CLAUDE.md (1 hunks)
  • docs/installation.md (5 hunks)
  • scripts/install.ps1 (1 hunks)
  • scripts/lib/Config.psd1 (3 hunks)
  • scripts/lib/Install-Common.psm1 (3 hunks)
  • scripts/tests/Config.Tests.ps1 (6 hunks)
  • scripts/tests/Install-Common.Tests.ps1 (4 hunks)
  • scripts/tests/install.Tests.ps1 (1 hunks)
🧰 Additional context used
📓 Path-based instructions (36)
scripts/**/*.ps1

📄 CodeRabbit inference engine (.agents/security/infrastructure-file-patterns.md)

PowerShell scripts in scripts directory (scripts/**/*.ps1) should trigger security agent review due to high security implications

scripts/**/*.ps1: Always include the multiline flag (?m) in regex patterns used for multi-line text processing in PowerShell validation scripts
Plan validation regex patterns must include the NNN-[name]-plan.md file naming pattern

Validation scripts belong in scripts/ directory; may duplicate to .agents/utilities/ for agent access

PowerShell installation scripts must handle per-repository and global installation paths correctly, with validation of agent file locations

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/*.{ps1,psm1,psd1}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Extract environment variations to .psd1 data files, keeping logic generic rather than hardcoding configuration in scripts

Convert PathInfo objects to string representations when passing to string-typed parameters to prevent type mismatch errors

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/lib/Install-Common.psm1
  • scripts/lib/Config.psd1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/*install*.ps1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Maintain backward compatibility with legacy scripts by refactoring them as thin wrappers (28-37 lines) that delegate to a unified implementation

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/install.ps1
scripts/**/*.{ps1,psm1,psd1}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-documentation-gap.md)

Create module-specific README documentation for PowerShell scripts and modules, including parameter documentation and usage examples

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/lib/Install-Common.psm1
  • scripts/lib/Config.psd1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/*.{ps1,psd1}?(@(test|spec))

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-install-scripts-session.md)

Use BeforeAll blocks for all variable initialization in Pester 5.x tests; avoid variable assignments outside BeforeAll during Discovery phase

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/lib/Config.psd1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/{install,setup}*.ps1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-install-scripts-session.md)

**/{install,setup}*.ps1: Detect remote bootstrap context via empty $PSScriptRoot when scripts are invoked via iex (remote execution)
Use thin wrapper pattern for legacy scripts to maintain backward compatibility while consolidating core logic into shared modules

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/install.ps1
**/*.ps1

📄 CodeRabbit inference engine (.agents/planning/prd-agent-consolidation.md)

PowerShell scripts must include inline documentation and header comments with usage instructions

User instruction files should be excluded from agent file copying during installation to prevent them from being treated as agent files

**/*.ps1: Use the (?m) multiline flag in regex patterns with ^ anchors in PowerShell to match at line beginnings, not just string beginnings
When fixing regex patterns that use ^ or $ anchors to match at line boundaries, ensure the (?m) multiline flag is present in the pattern
When regex patterns fail to match expected content (false positives/negatives), verify that necessary regex flags like (?m) are present before concluding the logic is incorrect

PowerShell scripts should explicitly return values in all code paths, especially when using WhatIf parameter - add explicit return $false in else blocks to avoid implicit null returns

Use .Path property to extract string value from PathInfo objects returned by Resolve-Path in PowerShell (e.g., (Resolve-Path $Path).Path instead of Resolve-Path $Path)

PowerShell scripts should normalize output line endings (convert CRLF to LF) when output is intended to be processed by shell commands like grep to ensure cross-platform compatibility

Use -cmatch instead of -match when pattern requires case-sensitive matching in PowerShell validation scripts (e.g., EPIC vs epic for naming conventions)

**/*.ps1: In PowerShell script scope, use exit with explicit exit codes instead of return; return exits with code 0 regardless of boolean value
Document the bash-PowerShell exit code contract explicitly in PowerShell script comments: exit code 0 means success, non-zero means failure

When combining ShouldProcess with PassThru in PowerShell cmdlets: always provide explicit return value in else branch when ShouldProcess returns false

Before executing any PowerShell generation script, audit its code for alignment with known user requirements and identify dead/unused functions

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/{install,*.ps1,*.json}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-instruction-files-gap.md)

Verify that all files referenced in installer configuration (InstructionsFile, SourceDir, etc.) exist in their expected locations before release

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
{install.ps1,build/**/*.{ps1,sh},scripts/**/*.{ps1,sh}}

📄 CodeRabbit inference engine (.agents/roadmap/epic-agent-consolidation.md)

Build script must generate platform-specific YAML frontmatter for VS Code and Copilot CLI variants at build time

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/scripts/tests/**/*.ps1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Add unit tests in 'scripts/tests/' directory for new VisualStudio configuration and installation functions

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/install*.ps1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

**/install*.ps1: Use consistent error handling patterns in install.ps1 and wrapper scripts that match existing Install-Common.psm1 conventions
Implement Find-VisualStudioAgentPath PowerShell function to discover Visual Studio agent paths by searching candidate directories with Get-Item and wildcard patterns

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/install.ps1
scripts/tests/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/planning/phase3-complete-handoff.md)

Create comprehensive Pester tests for validation scripts with at least 31 tests covering all validation functions and edge cases

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/pr-comments/PR-50/2625540786-plan.md)

**/*.Tests.ps1: Create comprehensive Pester test coverage for regex pattern fixes, including positive tests (checkboxes, numbered lists, plain lists, mixed formats), negative tests (empty/missing content, malformed patterns), edge cases (line endings, large datasets), and regression tests
Test regex patterns across different line ending formats (CRLF for Windows, LF for Unix) to ensure cross-platform compatibility

PowerShell script tests should include test coverage for parameter combinations like WhatIf + PassThru to ensure all code paths are exercised

**/*.Tests.ps1: Add BeforeEach cleanup block to Pester test contexts to prevent test pollution between tests
Use BeforeAll block in Pester tests to create isolated temp directories for test execution
Use AfterAll block in Pester tests to clean up and remove temp directories after all tests complete
Clean temp test directory using Get-ChildItem -Recurse | Remove-Item -Force pattern with -ErrorAction SilentlyContinue to safely remove test artifacts
Verify test isolation through file count assertions in Pester tests to detect if previous test files remain

Pre-compute collections before Pester hashtable initialization; pipeline operators inside hashtable index expressions are not supported

**/*.Tests.ps1: Include $LASTEXITCODE assertion tests in Pester test suites for PowerShell scripts invoked from bash hooks to validate exit code contracts
Verify that Pester tests for PowerShell scripts check both internal logic and external exit code behavior when scripts are executed from bash contexts

**/*.Tests.ps1: PowerShell cmdlets with 2+ switch parameters require combination testing: n parameters = n individual + C(n,2) pair tests minimum
Integration tests must include first-time setup scenario where config files don't exist yet
Organize PowerShell Pester test files with contexts for: Basic Functionality, Error Handling, Parameter Combinations, and Edge Cases

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
scripts/tests/**/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/pr-comments/PR-50/session-summary.md)

Create comprehensive Pester test coverage including positive test cases, negative test cases, edge cases, and regression tests for validation script changes

Pester test files must cover all 11 shared module functions in Install-Common.psm1, configuration validation, and entry point parameter validation

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/*.{md,json,yml,yaml,ps1,sh,bash,toml,ini,cfg,config,txt}

📄 CodeRabbit inference engine (.agents/retrospective/phase1-remediation-pr43.md)

Use relative paths only in documentation and configuration files; avoid absolute paths (e.g., C:\ on Windows) to prevent environment contamination and maintain cross-platform portability

Files:

  • scripts/tests/install.Tests.ps1
  • AGENTS.md
  • scripts/tests/Install-Common.Tests.ps1
  • CLAUDE.md
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
  • docs/installation.md
**/tests/**/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/retrospective/pr-feedback-remediation.md)

Create Pester tests following 5.x structure with test cases covering Pattern Detection, File Filtering, Exit Code Behavior, Reporting, and Edge Cases for validation scripts

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/*.{ps1,powershell}

📄 CodeRabbit inference engine (AGENTS.md)

Installation scripts should follow the directory structure pattern: global installation to VS Code/Copilot/Claude config directories, per-repository installation to .github/agents/ or .claude/agents/

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
{.githooks/**,**/.github/**,**/infrastructure/**,**/config/**,**/*.tf,**/*.yml,**/*.yaml}

📄 CodeRabbit inference engine (.agents/metrics/baseline-report.md)

Infrastructure files (including .githooks/pre-commit) must receive security review before deployment

Files:

  • .github/instructions/security.instructions.md
  • .github/instructions/testing.instructions.md
  • .github/copilot-instructions.md
  • .github/instructions/agent-prompts.instructions.md
scripts/lib/Install-Common.psm1

📄 CodeRabbit inference engine (.agents/planning/cva-install-scripts.md)

scripts/lib/Install-Common.psm1: Extract all duplicated installation logic into a shared PowerShell module (Install-Common.psm1) with functions including Get-InstallConfig, Test-SourceDirectory, Initialize-Destination, Get-AgentFiles, Copy-AgentFile, Test-GitRepository, Initialize-AgentsDirectories, Install-InstructionsFile, Write-InstallHeader, and Write-InstallComplete
Use markdown-compatible HTML comment markers (<!-- BEGIN: ai-agents installer --> and <!-- END: ai-agents installer -->) to create upgradeable content blocks in instructions files, replacing existing blocks on updates while preserving user content outside the markers
Include validation to verify source directories exist before installation, and provide clear error messages indicating the expected source path if validation fails
For repository-scoped installations, validate that the target path is a git repository before proceeding, and prompt the user to confirm if git repository validation fails
Display interactive prompts when overwriting existing agent files unless the -Force switch is specified, asking for confirmation with clear feedback on the action taken (Installed, Updated, or Skipped)

Files:

  • scripts/lib/Install-Common.psm1
**/*.psm1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Group PowerShell functions by concern using #region blocks and use explicit Export-ModuleMember at module end

Files:

  • scripts/lib/Install-Common.psm1
**/Install-Common.psm1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Add Visual Studio-specific messages to Write-InstallComplete function with text 'IMPORTANT: Restart Visual Studio to load new agents' and usage example '@agent-name in Copilot Chat'

Files:

  • scripts/lib/Install-Common.psm1
**/*{Common,Utilities,Shared}.psm1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-17-session-failures.md)

When reading utility scripts, identify functions that are defined but never called, and remove dead/unused functions before execution

Files:

  • scripts/lib/Install-Common.psm1
**/*.md

📄 CodeRabbit inference engine (.agents/architecture/ADR-001-markdown-linting.md)

**/*.md: Add language identifiers to all fenced code blocks (MD040). Use appropriate language identifiers: csharp for C#, powershell for PowerShell, bash for shell, json for JSON, yaml for YAML, markdown for Markdown, text for plain text or generic/pseudo code
Wrap generic types in backticks to escape angle brackets (e.g., ArrayPool<T> instead of ArrayPool) to comply with MD033 inline HTML restrictions and ensure proper rendering
Add blank lines around code blocks to comply with MD031 markdown linting requirements
Add blank lines around lists to comply with MD032 markdown linting requirements
Add blank lines around headings to comply with MD022 markdown linting requirements
Use ATX-style headings (# Heading) consistently across all markdown documents (MD003)
Use fenced code block style (triple backticks) consistently, with backtick delimiters rather than tildes (MD046, MD048)
Allow only specific HTML elements in markdown: <br>, <kbd>, <sup>, <sub>. Escape or avoid other inline HTML elements to comply with MD033 restrictions

**/*.md: Use skill ID convention format: Skill-[Category]-[Number] for skills and Anti-[Category]-[Number] for anti-patterns
Each skill must follow the required structure: Statement (max 15 words), Context, Atomicity score (0-100%), Evidence, Impact, and Tags
Score skills for atomicity using the scale: 90-100% (Excellent - ready for storage), 70-89% (Good - may need refinement), 50-69% (Acceptable - consider splitting), <50% (Needs Work - too vague)
Tag each skill with one of: helpful (contributed to success), harmful (caused failure), or neutral (no measurable impact)
When citing skills during implementation, use the format: Applying [Skill-ID], Strategy [description], Expected [outcome], Result [actual outcome], Skill Validated [yes/no]
Skills should be atomic learning statements of maximum 15 words
Skills must include measurable outcomes in the Impact field

**/*.md: Always specify language identifiers on fenc...

Files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md

⚙️ CodeRabbit configuration file

**/*.md: Writing Quality: - Grade 9 reading level - Active voice, direct address - Short sentences (under 15 words ideal) - No fluff, filler, or marketing language - Replace adjectives with data where possible - Every sentence must pass the "so what" test
Flag: - Passive voice - Vague language (nearly, some, almost, very) - Jargon without definitions - Broken links and outdated procedures - Inconsistency with code changes in same PR - Missing context for new features or APIs
Ignore (handled by .markdownlint-cli2.yaml): - Markdown formatting and style - Heading level choices - Link formatting variations - Minor punctuation preferences

Files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
**/AGENTS.md

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Update AGENTS.md documentation with Visual Studio 2026 repository-level installation instructions including agent file location '.github/agents/' and VS-specific usage examples

Files:

  • AGENTS.md
AGENTS.md

📄 CodeRabbit inference engine (.agents/planning/phase3-complete-handoff.md)

Document all artifact naming patterns and validation procedures in AGENTS.md under 'Naming Conventions' section with examples and references to automation tooling

Refer to AGENTS.md for complete project instructions and maintain all canonical agent documentation there following the DRY principle

Files:

  • AGENTS.md
**/*.{md,markdown}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-17-session-failures.md)

Do not include auto-generated headers in generated files

Files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
scripts/lib/Config.psd1

📄 CodeRabbit inference engine (.agents/planning/cva-install-scripts.md)

scripts/lib/Config.psd1: Consolidate environment and scope-specific configuration into a PowerShell data file (Config.psd1) containing: source directories, file patterns, destination paths (as scriptblocks for dynamic resolution), instructions file names, and known bugs by environment
Use agent file patterns specific to each environment: *.md for Claude, *.agent.md for Copilot CLI and VSCode, ensuring only files matching the pattern are installed
For Copilot CLI global installation, include a warning about known issue #452 (user-level agents not being loaded) and provide guidance on workarounds if available

Files:

  • scripts/lib/Config.psd1
**/*.psd1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Use $ExecutionContext.InvokeCommand.ExpandString() for evaluating path expressions in PowerShell data files instead of raw variables

Files:

  • scripts/lib/Config.psd1
**/Config.psd1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Add 'VisualStudio' environment entry to Config.psd1 with DisplayName, SourceDir, FilePattern, Global, and Repo configuration properties

Files:

  • scripts/lib/Config.psd1
**/CLAUDE.md

📄 CodeRabbit inference engine (.agents/governance/agent-consolidation-process.md)

Update the agent catalog (CLAUDE.md) to remove deprecated agents and reflect consolidated agent capabilities

Add reference to naming conventions and link to .agents/governance/naming-conventions.md in main agent documentation (CLAUDE.md)

Files:

  • CLAUDE.md
CLAUDE.md

📄 CodeRabbit inference engine (.agents/governance/steering-committee-charter.md)

Agent catalog table must be maintained in CLAUDE.md

Update CLAUDE.md to reference central naming conventions document at .agents/governance/naming-conventions.md for sequenced artifact patterns, type-prefixed patterns, and naming rules.

Files:

  • CLAUDE.md
scripts/install.ps1

📄 CodeRabbit inference engine (.agents/planning/cva-install-scripts.md)

scripts/install.ps1: Create a unified PowerShell install entry point (install.ps1) that accepts parameters -Environment [Claude|Copilot|VSCode], -Scope [Global|Local], and -RepoPath to support both local and remote installation via iex execution
Support remote PowerShell execution via iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/rjmurillo/ai-agents/main/scripts/install.ps1')) by detecting remote execution context, downloading dependencies to temp directory, and providing interactive prompts when parameters are not specified
Implement parameter validation in install scripts to ensure -Environment parameter accepts only: Claude, Copilot, VSCode; -Scope is either Global or Local (derived from parameter set); and -RepoPath is provided when not using Global scope

Files:

  • scripts/install.ps1
**/install.ps1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Detect remote execution context via empty $PSScriptRoot and download dependencies to $env:TEMP for Invoke-Expression scenarios

**/install.ps1: Update install.ps1 ValidateSet parameter to include 'VisualStudio' alongside existing 'Claude', 'Copilot', and 'VSCode' options
Add 'Visual Studio 2026' option to the interactive menu in install.ps1 as item 4, maintaining consistent formatting with existing environment options
Deploy agents to '.github/agents/' directory for repository-level Visual Studio installation, reusing VS Code agent source from 'src/vs-code-agents'
Deploy instructions to '.github/' directory with filename 'copilot-instructions.md' for repository-level Visual Studio installation
Repository-level installation must copy all *.agent.md files from SourceDir to '.github/agents/' destination directory
Support '-Force' parameter in install.ps1 to overwrite existing agent and instruction files when specified

Files:

  • scripts/install.ps1
scripts/*.ps1

📄 CodeRabbit inference engine (.agents/pr-comments/PR-52/summary.md)

PowerShell error handling must use direct exit 1 statements instead of conditional if ($PassThru) { return $false } patterns to ensure proper exit code propagation in error paths

Files:

  • scripts/install.ps1
**/docs/**/*.md

📄 CodeRabbit inference engine (.agents/skills/documentation.md)

Structure requirements documents with Purpose, Configuration, Required Rules, Disabled Rules, Common Patterns, Troubleshooting, and References sections

Files:

  • docs/installation.md
docs/**/*.md

📄 CodeRabbit inference engine (docs/markdown-linting.md)

docs/**/*.md: Every fenced code block must include a language identifier
Fenced code blocks must be surrounded by blank lines
Lists must be surrounded by blank lines
Headings must be surrounded by blank lines
Inline HTML is restricted; generic types must be wrapped in backticks to avoid being interpreted as HTML tags
Use appropriate language identifiers for code blocks: 'csharp' for C#, 'powershell' for PowerShell, 'bash' for Bash/Shell, 'json' for JSON, 'yaml' for YAML, 'markdown' for Markdown examples, 'text' for plain text/pseudo-code, 'sql' for SQL, 'xml' or 'html' for XML/HTML, 'javascript' for JavaScript, 'typescript' for TypeScript, 'python' for Python
Exclude node_modules/ and .agents/ directories from markdown linting

Create dedicated documentation pages for significant features, including installation guides with parameters and usage examples

Files:

  • docs/installation.md
🧠 Learnings (8)
📚 Learning: 2025-12-18T02:19:41.405Z
Learnt from: CR
Repo: rjmurillo/ai-agents PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-18T02:19:41.405Z
Learning: Applies to src/claude/**/*.md : Claude Code agent files should be installed globally to ~/.claude/agents/ or per-repository to .claude/agents/, restarting Claude Code after installation

Applied to files:

  • AGENTS.md
📚 Learning: 2025-12-16T06:26:21.783Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/qa.shared.md:1-311
Timestamp: 2025-12-16T06:26:21.783Z
Learning: In the rjmurillo/ai-agents repository, follow the project's Markdown lint rules defined in .markdownlint-cli2.yaml. Do not flag MD031/MD032 (blank lines around fences) or similar style issues in Markdown files if the repository's markdownlint configuration passes; rely on the config to determine formatting and style decisions.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T06:26:44.230Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/implementer.shared.md:33-40
Timestamp: 2025-12-16T06:26:44.230Z
Learning: In the rjmurillo/ai-agents repository, markdownlint issues should be governed by the repository's .markdownlint-cli2.yaml configuration. Do not flag or enforce markdown formatting/style violations that are not surfaced by the configured rules. Apply this rule to all Markdown files (e.g., templates/agents/implementer.shared.md and others) and only flag issues that the project's markdownlint config would detect.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T06:26:44.208Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/planner.shared.md:73-121
Timestamp: 2025-12-16T06:26:44.208Z
Learning: In this repository (rjmurillo/ai-agents), do not flag Markdown formatting or style issues (MD031, MD032, heading levels, link formatting, punctuation) for Markdown files. These are already ignored by the project’s .markdownlint-cli2.yaml; rely on that configuration and the repository's coding guidelines for Markdown handling.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T06:27:04.317Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: src/copilot-cli/analyst.agent.md:39-44
Timestamp: 2025-12-16T06:27:04.317Z
Learning: In the rjmurillo/ai-agents repository, do not flag MD031 (blank lines around fenced code blocks) or MD032 (blank lines around lists) violations in Markdown files. These formatting rules are configured in the project’s .markdownlint-cli2.yaml, and such style issues do not affect agent instruction functionality. Apply this pattern to all Markdown files (recursively) and focus review attention on issues that affect behavior, correctness, or other lint rules.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T08:00:20.752Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/roadmap.shared.md:124-174
Timestamp: 2025-12-16T08:00:20.752Z
Learning: Review Markdown files to ensure nested code fences follow the rule: the outer fence uses more backticks than the inner fence (e.g., an outer `````` with four backticks containing an inner ```mermaid``` fence). This follows CommonMark conventions; verify that nesting does not break rendering by using a greater number of backticks for the outer fence than the inner one.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T01:14:43.697Z
Learnt from: CR
Repo: rjmurillo/ai-agents PR: 0
File: docs/installation.md:0-0
Timestamp: 2025-12-16T01:14:43.697Z
Learning: Installation paths are platform-specific: Claude Code uses `~/.claude/agents`, Copilot CLI uses `~/.copilot/agents`, VS Code uses `%APPDATA%/Code/User/prompts` (Windows) or `~/.config/Code/User/prompts` (macOS/Linux)

Applied to files:

  • docs/installation.md
📚 Learning: 2025-12-16T01:14:43.697Z
Learnt from: CR
Repo: rjmurillo/ai-agents PR: 0
File: docs/installation.md:0-0
Timestamp: 2025-12-16T01:14:43.697Z
Learning: Applies to docs/.github/agents/** : For Copilot CLI and VS Code repository installations, commit changes to `.github/agents` directory and `.agents` artifact directory with message: `git add .github/agents .agents && git commit -m 'feat: add Copilot agent system'`

Applied to files:

  • docs/installation.md
🪛 GitHub Actions: Validate Path Normalization
AGENTS.md

[error] 132-132: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 132)


[error] 140-140: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 140)


[error] 162-162: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 162)


[error] 944-944: macOS User Path violation detected. Content references a macOS user home path; should use a relative path instead. (Line 944)


[error] 944-944: Linux Home Path violation detected. Content references a Linux user home path; should use a relative path instead. (Line 944)

docs/installation.md

[error] 35-35: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 35)


[error] 47-47: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 47)


[error] 68-68: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 68)


[error] 72-72: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 72)


[error] 76-76: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 76)

🪛 LanguageTool
docs/installation.md

[uncategorized] ~94-~94: The official name of this software platform is spelled with a capital “H”.
Context: ...LAUDE.md(repo root) | | Copilot CLI |.github/agents/| (same directory) |.github/...

(GITHUB)


[uncategorized] ~94-~94: The official name of this software platform is spelled with a capital “H”.
Context: ... .github/agents/ | (same directory) | .github/copilot-instructions.md | | VS Code | ...

(GITHUB)


[uncategorized] ~95-~95: The official name of this software platform is spelled with a capital “H”.
Context: .../copilot-instructions.md| | VS Code |.github/agents/| (same directory) |.github/...

(GITHUB)


[uncategorized] ~95-~95: The official name of this software platform is spelled with a capital “H”.
Context: ... .github/agents/ | (same directory) | .github/copilot-instructions.md | ### .agents...

(GITHUB)

🔍 Remote MCP DeepWiki

Below is additional context relevant to reviewing PR #58 (“feat(installer): add command and prompt file installation support”) drawn from the repo’s DeepWiki documentation and code search.

– DeepWiki’s “Installation Module Architecture” page shows how the unified installer is structured:
• Config.psd1 defines per-scope Keys (InstructionsDest, plus new CommandsDir/CommandFiles and PromptFiles) that feed into Get-InstallConfig.
• scripts/lib/Install-Common.psm1 exposes Install-InstructionsFile (existing), Install-CommandFiles, and Install-PromptFiles, wiring them together in scripts/install.ps1’s main flow.
• A sequence diagram illustrates: load config → Install-InstructionsFile → (if CommandsDir) Install-CommandFiles → (if PromptFiles) Install-PromptFiles → summary output.

– In scripts/lib/Install-Common.psm1, code search shows:
• Install-CommandFiles (lines 110–165) accepts a CommandsDir path and CommandFiles array, iterates each file, creates target directories, copies with overwrite logic, and returns a hashtable of Installed/Updated/Skipped counts.
• Install-PromptFiles (lines 170–230) similarly transforms each source “.agent.md” into “.prompt.md” in the configured PromptFiles path, with the same stats hashtable pattern.
• Get-InstallConfig (around line 45) now appends three new entries—CommandsDir, CommandFiles, PromptFiles—into the merged configuration object returned to install.ps1.

– In scripts/install.ps1, code search reveals the integration points (around line 75):
• After copying core agent files, if the config object’s CommandsDir is non-empty, it invokes Install-CommandFiles and prints “Commands: Installed/Updated/Skipped”.
• Likewise, if PromptFiles is defined, it calls Install-PromptFiles and prints “Prompts: Installed/Updated/Skipped”.
• Existing logic for instructions file installation remains unchanged.

This additional context confirms that the PR’s new installer functions are correctly wired into the existing pipeline and that their parameters and return values align with the established pattern for Install-InstructionsFile.

🔇 Additional comments (33)
.github/instructions/testing.instructions.md (1)

12-12: LGTM - Improved formatting and useful testing guidance.

The blank lines comply with MD032, and the new principles (coverage target and Mock usage) are standard best practices.

Also applies to: 24-29

.github/instructions/agent-prompts.instructions.md (1)

12-12: LGTM - Formatting improvement.

Blank lines added for MD032 compliance with no content changes.

Also applies to: 23-23, 29-29

.github/instructions/security.instructions.md (1)

12-22: LGTM - Comprehensive security guidance expansion.

The additions cover:

  • Complete OWASP Top 10 coverage
  • Detailed critical patterns for auth, secrets, input validation, and output encoding
  • File path triggers for mandatory security review
  • Full STRIDE threat model

All align with security best practices and coding guidelines.

Also applies to: 27-51, 53-71

AGENTS.md (2)

360-368: LGTM - File types documentation is clear and accurate.

The new sections consistently document agent files, prompt files, and command files across all platforms (VS Code, Copilot CLI, Claude) with clear pattern explanations.

Also applies to: 401-409, 434-447


452-454: LGTM - Updated Claude notes reflect new command file support.

The notes now correctly mention slash commands and override behavior.

scripts/lib/Config.psd1 (2)

39-43: LGTM - Claude command configuration follows established pattern.

CommandsDir and CommandFiles added consistently for both Global and Repo scopes, matching the existing configuration structure.

Also applies to: 49-53


71-74: LGTM - Prompt file configuration consistent across platforms.

PromptFiles arrays added for Copilot and VSCode in both Global and Repo scopes. Structure aligns with existing patterns.

Also applies to: 80-83, 96-99, 105-108

CLAUDE.md (1)

22-47: LGTM - Mandatory session protocol addresses amnesia problem.

The new section clearly establishes non-negotiable requirements for session continuity with minimal checklist and proper AGENTS.md cross-reference. The "expert amnesiac" framing effectively communicates the issue.

.github/copilot-instructions.md (1)

24-49: LGTM - Consistent session protocol for Copilot.

The mandatory session protocol section mirrors CLAUDE.md with correct relative path to AGENTS.md. Maintains consistency across platforms.

scripts/tests/install.Tests.ps1 (1)

188-222: LGTM - Test coverage for new command and prompt installation.

The new test contexts verify integration of Install-CommandFiles and Install-PromptFiles functions, configuration checks, path resolution, and output messaging. Pattern matches existing tests.

scripts/install.ps1 (2)

328-343: LGTM! Command installation logic is solid.

The conditional checks and path resolution follow the established pattern. Stats reporting is consistent with existing flow.


345-358: LGTM! Prompt file installation correctly reuses agent destination.

No separate path resolution needed since prompt files are generated alongside agent files in the same directory.

scripts/tests/Config.Tests.ps1 (6)

136-148: Comprehensive test coverage for Claude command configuration.

Tests validate presence, pattern matching, and expected file contents.


165-176: LGTM! Repo scope command tests mirror global scope pattern.


229-236: LGTM! Copilot prompt file configuration tests look good.


252-259: LGTM! Repo scope matches global pattern.


295-302: LGTM! VSCode global prompt tests follow established pattern.


318-325: LGTM! VSCode repo tests complete comprehensive coverage.

All environments (Claude, Copilot, VSCode) and scopes (Global, Repo) now have test coverage for the new configuration fields.

scripts/lib/Install-Common.psm1 (4)

78-80: LGTM! Configuration field additions follow existing pattern.

The three new fields (CommandsDir, CommandFiles, PromptFiles) are exposed via the merged configuration object, consistent with existing fields like InstructionsFile.


376-454: LGTM! Install-CommandFiles implementation is solid.

The function follows established patterns from Copy-AgentFile:

  • Creates destination directory if needed
  • Handles missing source files gracefully (warns, continues)
  • Prompts before overwriting unless -Force is specified
  • Returns consistent stats hashtable

Error handling and user interaction are appropriate.


456-532: LGTM! Install-PromptFiles correctly transforms agent files to prompts.

Key implementation details:

  • Transforms .agent.md.prompt.md using regex replacement (line 511)
  • Reuses existing agent destination directory (doesn't create separately)
  • Follows same error handling and prompting patterns as Install-CommandFiles

The regex pattern '\.agent\.md$' correctly anchors at end and escapes dots.


757-758: LGTM! Module exports updated correctly.

Both new functions are exposed as part of the public API.

docs/installation.md (6)

83-87: LGTM! Global paths table accurately reflects new file types.

The restructured table clearly shows where agents and commands/prompts are installed for each environment.


91-95: LGTM! Repository paths table includes new command/prompt locations.


115-133: Excellent addition! Clarifies what files are installed and why.

The explanation of file types, extensions, and the auto-generation of prompt files helps users understand the installation artifacts.


258-258: LGTM! Commit command updated to include instructions file.


270-271: LGTM! Uninstall commands include new directories.


284-285: LGTM! Repository cleanup includes new command directories.

scripts/tests/Install-Common.Tests.ps1 (5)

62-87: LGTM! Configuration tests validate CommandsDir and CommandFiles.

Tests cover both Global and Repo scopes with appropriate assertions (pattern matching for Global, exact paths for Repo).


110-122: LGTM! Copilot PromptFiles configuration tests look good.


143-155: LGTM! VSCode PromptFiles tests complete the coverage.


496-575: Excellent test coverage for Install-CommandFiles.

Tests cover:

  • Directory creation
  • Single and multiple file installation
  • Update scenarios with -Force
  • Error handling (missing source files)
  • Partial success when some files are missing

Test isolation using BeforeEach ensures clean state. Stats validation confirms correct counting.


577-651: Excellent test coverage for Install-PromptFiles.

Tests verify critical behavior:

  • Name transformation (.agent.md.prompt.md)
  • Confirmation that source filename is NOT used in destination (line 605)
  • Multiple file handling
  • Update scenarios
  • Error handling for missing files

The transformation verification on lines 604-605 is particularly important - confirms files are transformed, not duplicated.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (5)
AGENTS.md (4)

132-132: Fix absolute Windows path in installation example.

Pipeline failure: Windows path detected. Replace with placeholder text.

🔎 Apply this diff to fix the path:
-.\scripts\install-vscode-repo.ps1 -RepoPath "C:\Path\To\Your\Repo"
+.\scripts\install-vscode-repo.ps1 -RepoPath "<path-to-repo>"

140-140: Fix absolute Windows path in installation example.

Pipeline failure: Windows path detected. Replace with placeholder text.

🔎 Apply this diff to fix the path:
-.\scripts\install-copilot-cli-repo.ps1 -RepoPath "C:\Path\To\Your\Repo"
+.\scripts\install-copilot-cli-repo.ps1 -RepoPath "<path-to-repo>"

162-162: Fix absolute Windows path in installation example.

Pipeline failure: Windows path detected. Replace with placeholder text.

🔎 Apply this diff to fix the path:
-.\scripts\install-claude-repo.ps1 -RepoPath "C:\Path\To\Your\Repo"
+.\scripts\install-claude-repo.ps1 -RepoPath "<path-to-repo>"

944-944: Fix absolute Unix paths in documentation section.

Pipeline failure: macOS and Linux home paths detected. Use relative path pattern.

🔎 Apply this diff to fix the paths:
-- Forbidden patterns: `[A-Z]:\` (Windows), `/Users/` (macOS), `/home/` (Linux)
+- Forbidden patterns: `[A-Z]:\` (Windows), `~/` prefix for user home on Unix systems
docs/installation.md (1)

35-76: Replace absolute path placeholders with relative paths in command examples.

Lines 35, 47, 68, 72, 76 contain Windows absolute path placeholders (C:\Path\To\Repo) that violate documentation standards. Use "." (current directory) instead, consistent with line 43:

  • Line 35: .\scripts\install.ps1 -Environment Claude -RepoPath "."
  • Line 47: .\scripts\install.ps1 -Environment VSCode -RepoPath "."
  • Lines 68, 72, 76: Similar updates
📜 Review details

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 41ef2bd and db5255a.

📒 Files selected for processing (13)
  • .github/copilot-instructions.md (1 hunks)
  • .github/instructions/agent-prompts.instructions.md (2 hunks)
  • .github/instructions/security.instructions.md (2 hunks)
  • .github/instructions/testing.instructions.md (2 hunks)
  • AGENTS.md (3 hunks)
  • CLAUDE.md (1 hunks)
  • docs/installation.md (5 hunks)
  • scripts/install.ps1 (1 hunks)
  • scripts/lib/Config.psd1 (3 hunks)
  • scripts/lib/Install-Common.psm1 (3 hunks)
  • scripts/tests/Config.Tests.ps1 (6 hunks)
  • scripts/tests/Install-Common.Tests.ps1 (4 hunks)
  • scripts/tests/install.Tests.ps1 (1 hunks)
🧰 Additional context used
📓 Path-based instructions (36)
scripts/**/*.ps1

📄 CodeRabbit inference engine (.agents/security/infrastructure-file-patterns.md)

PowerShell scripts in scripts directory (scripts/**/*.ps1) should trigger security agent review due to high security implications

scripts/**/*.ps1: Always include the multiline flag (?m) in regex patterns used for multi-line text processing in PowerShell validation scripts
Plan validation regex patterns must include the NNN-[name]-plan.md file naming pattern

Validation scripts belong in scripts/ directory; may duplicate to .agents/utilities/ for agent access

PowerShell installation scripts must handle per-repository and global installation paths correctly, with validation of agent file locations

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/*.{ps1,psm1,psd1}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Extract environment variations to .psd1 data files, keeping logic generic rather than hardcoding configuration in scripts

Convert PathInfo objects to string representations when passing to string-typed parameters to prevent type mismatch errors

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/lib/Install-Common.psm1
  • scripts/lib/Config.psd1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/*install*.ps1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Maintain backward compatibility with legacy scripts by refactoring them as thin wrappers (28-37 lines) that delegate to a unified implementation

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/install.ps1
scripts/**/*.{ps1,psm1,psd1}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-documentation-gap.md)

Create module-specific README documentation for PowerShell scripts and modules, including parameter documentation and usage examples

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/lib/Install-Common.psm1
  • scripts/lib/Config.psd1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/*.{ps1,psd1}?(@(test|spec))

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-install-scripts-session.md)

Use BeforeAll blocks for all variable initialization in Pester 5.x tests; avoid variable assignments outside BeforeAll during Discovery phase

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/lib/Config.psd1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/{install,setup}*.ps1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-install-scripts-session.md)

**/{install,setup}*.ps1: Detect remote bootstrap context via empty $PSScriptRoot when scripts are invoked via iex (remote execution)
Use thin wrapper pattern for legacy scripts to maintain backward compatibility while consolidating core logic into shared modules

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/install.ps1
**/*.ps1

📄 CodeRabbit inference engine (.agents/planning/prd-agent-consolidation.md)

PowerShell scripts must include inline documentation and header comments with usage instructions

User instruction files should be excluded from agent file copying during installation to prevent them from being treated as agent files

**/*.ps1: Use the (?m) multiline flag in regex patterns with ^ anchors in PowerShell to match at line beginnings, not just string beginnings
When fixing regex patterns that use ^ or $ anchors to match at line boundaries, ensure the (?m) multiline flag is present in the pattern
When regex patterns fail to match expected content (false positives/negatives), verify that necessary regex flags like (?m) are present before concluding the logic is incorrect

PowerShell scripts should explicitly return values in all code paths, especially when using WhatIf parameter - add explicit return $false in else blocks to avoid implicit null returns

Use .Path property to extract string value from PathInfo objects returned by Resolve-Path in PowerShell (e.g., (Resolve-Path $Path).Path instead of Resolve-Path $Path)

PowerShell scripts should normalize output line endings (convert CRLF to LF) when output is intended to be processed by shell commands like grep to ensure cross-platform compatibility

Use -cmatch instead of -match when pattern requires case-sensitive matching in PowerShell validation scripts (e.g., EPIC vs epic for naming conventions)

**/*.ps1: In PowerShell script scope, use exit with explicit exit codes instead of return; return exits with code 0 regardless of boolean value
Document the bash-PowerShell exit code contract explicitly in PowerShell script comments: exit code 0 means success, non-zero means failure

When combining ShouldProcess with PassThru in PowerShell cmdlets: always provide explicit return value in else branch when ShouldProcess returns false

Before executing any PowerShell generation script, audit its code for alignment with known user requirements and identify dead/unused functions

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/{install,*.ps1,*.json}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-instruction-files-gap.md)

Verify that all files referenced in installer configuration (InstructionsFile, SourceDir, etc.) exist in their expected locations before release

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
{install.ps1,build/**/*.{ps1,sh},scripts/**/*.{ps1,sh}}

📄 CodeRabbit inference engine (.agents/roadmap/epic-agent-consolidation.md)

Build script must generate platform-specific YAML frontmatter for VS Code and Copilot CLI variants at build time

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
**/scripts/tests/**/*.ps1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Add unit tests in 'scripts/tests/' directory for new VisualStudio configuration and installation functions

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/install*.ps1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

**/install*.ps1: Use consistent error handling patterns in install.ps1 and wrapper scripts that match existing Install-Common.psm1 conventions
Implement Find-VisualStudioAgentPath PowerShell function to discover Visual Studio agent paths by searching candidate directories with Get-Item and wildcard patterns

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/install.ps1
scripts/tests/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/planning/phase3-complete-handoff.md)

Create comprehensive Pester tests for validation scripts with at least 31 tests covering all validation functions and edge cases

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/pr-comments/PR-50/2625540786-plan.md)

**/*.Tests.ps1: Create comprehensive Pester test coverage for regex pattern fixes, including positive tests (checkboxes, numbered lists, plain lists, mixed formats), negative tests (empty/missing content, malformed patterns), edge cases (line endings, large datasets), and regression tests
Test regex patterns across different line ending formats (CRLF for Windows, LF for Unix) to ensure cross-platform compatibility

PowerShell script tests should include test coverage for parameter combinations like WhatIf + PassThru to ensure all code paths are exercised

**/*.Tests.ps1: Add BeforeEach cleanup block to Pester test contexts to prevent test pollution between tests
Use BeforeAll block in Pester tests to create isolated temp directories for test execution
Use AfterAll block in Pester tests to clean up and remove temp directories after all tests complete
Clean temp test directory using Get-ChildItem -Recurse | Remove-Item -Force pattern with -ErrorAction SilentlyContinue to safely remove test artifacts
Verify test isolation through file count assertions in Pester tests to detect if previous test files remain

Pre-compute collections before Pester hashtable initialization; pipeline operators inside hashtable index expressions are not supported

**/*.Tests.ps1: Include $LASTEXITCODE assertion tests in Pester test suites for PowerShell scripts invoked from bash hooks to validate exit code contracts
Verify that Pester tests for PowerShell scripts check both internal logic and external exit code behavior when scripts are executed from bash contexts

**/*.Tests.ps1: PowerShell cmdlets with 2+ switch parameters require combination testing: n parameters = n individual + C(n,2) pair tests minimum
Integration tests must include first-time setup scenario where config files don't exist yet
Organize PowerShell Pester test files with contexts for: Basic Functionality, Error Handling, Parameter Combinations, and Edge Cases

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
scripts/tests/**/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/pr-comments/PR-50/session-summary.md)

Create comprehensive Pester test coverage including positive test cases, negative test cases, edge cases, and regression tests for validation script changes

Pester test files must cover all 11 shared module functions in Install-Common.psm1, configuration validation, and entry point parameter validation

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/*.{md,json,yml,yaml,ps1,sh,bash,toml,ini,cfg,config,txt}

📄 CodeRabbit inference engine (.agents/retrospective/phase1-remediation-pr43.md)

Use relative paths only in documentation and configuration files; avoid absolute paths (e.g., C:\ on Windows) to prevent environment contamination and maintain cross-platform portability

Files:

  • scripts/tests/install.Tests.ps1
  • AGENTS.md
  • scripts/tests/Install-Common.Tests.ps1
  • CLAUDE.md
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
  • docs/installation.md
**/tests/**/*.Tests.ps1

📄 CodeRabbit inference engine (.agents/retrospective/pr-feedback-remediation.md)

Create Pester tests following 5.x structure with test cases covering Pattern Detection, File Filtering, Exit Code Behavior, Reporting, and Edge Cases for validation scripts

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
**/*.{ps1,powershell}

📄 CodeRabbit inference engine (AGENTS.md)

Installation scripts should follow the directory structure pattern: global installation to VS Code/Copilot/Claude config directories, per-repository installation to .github/agents/ or .claude/agents/

Files:

  • scripts/tests/install.Tests.ps1
  • scripts/tests/Install-Common.Tests.ps1
  • scripts/tests/Config.Tests.ps1
  • scripts/install.ps1
{.githooks/**,**/.github/**,**/infrastructure/**,**/config/**,**/*.tf,**/*.yml,**/*.yaml}

📄 CodeRabbit inference engine (.agents/metrics/baseline-report.md)

Infrastructure files (including .githooks/pre-commit) must receive security review before deployment

Files:

  • .github/instructions/security.instructions.md
  • .github/instructions/testing.instructions.md
  • .github/copilot-instructions.md
  • .github/instructions/agent-prompts.instructions.md
scripts/lib/Install-Common.psm1

📄 CodeRabbit inference engine (.agents/planning/cva-install-scripts.md)

scripts/lib/Install-Common.psm1: Extract all duplicated installation logic into a shared PowerShell module (Install-Common.psm1) with functions including Get-InstallConfig, Test-SourceDirectory, Initialize-Destination, Get-AgentFiles, Copy-AgentFile, Test-GitRepository, Initialize-AgentsDirectories, Install-InstructionsFile, Write-InstallHeader, and Write-InstallComplete
Use markdown-compatible HTML comment markers (<!-- BEGIN: ai-agents installer --> and <!-- END: ai-agents installer -->) to create upgradeable content blocks in instructions files, replacing existing blocks on updates while preserving user content outside the markers
Include validation to verify source directories exist before installation, and provide clear error messages indicating the expected source path if validation fails
For repository-scoped installations, validate that the target path is a git repository before proceeding, and prompt the user to confirm if git repository validation fails
Display interactive prompts when overwriting existing agent files unless the -Force switch is specified, asking for confirmation with clear feedback on the action taken (Installed, Updated, or Skipped)

Files:

  • scripts/lib/Install-Common.psm1
**/*.psm1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Group PowerShell functions by concern using #region blocks and use explicit Export-ModuleMember at module end

Files:

  • scripts/lib/Install-Common.psm1
**/Install-Common.psm1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Add Visual Studio-specific messages to Write-InstallComplete function with text 'IMPORTANT: Restart Visual Studio to load new agents' and usage example '@agent-name in Copilot Chat'

Files:

  • scripts/lib/Install-Common.psm1
**/*{Common,Utilities,Shared}.psm1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-17-session-failures.md)

When reading utility scripts, identify functions that are defined but never called, and remove dead/unused functions before execution

Files:

  • scripts/lib/Install-Common.psm1
**/*.md

📄 CodeRabbit inference engine (.agents/architecture/ADR-001-markdown-linting.md)

**/*.md: Add language identifiers to all fenced code blocks (MD040). Use appropriate language identifiers: csharp for C#, powershell for PowerShell, bash for shell, json for JSON, yaml for YAML, markdown for Markdown, text for plain text or generic/pseudo code
Wrap generic types in backticks to escape angle brackets (e.g., ArrayPool<T> instead of ArrayPool) to comply with MD033 inline HTML restrictions and ensure proper rendering
Add blank lines around code blocks to comply with MD031 markdown linting requirements
Add blank lines around lists to comply with MD032 markdown linting requirements
Add blank lines around headings to comply with MD022 markdown linting requirements
Use ATX-style headings (# Heading) consistently across all markdown documents (MD003)
Use fenced code block style (triple backticks) consistently, with backtick delimiters rather than tildes (MD046, MD048)
Allow only specific HTML elements in markdown: <br>, <kbd>, <sup>, <sub>. Escape or avoid other inline HTML elements to comply with MD033 restrictions

**/*.md: Use skill ID convention format: Skill-[Category]-[Number] for skills and Anti-[Category]-[Number] for anti-patterns
Each skill must follow the required structure: Statement (max 15 words), Context, Atomicity score (0-100%), Evidence, Impact, and Tags
Score skills for atomicity using the scale: 90-100% (Excellent - ready for storage), 70-89% (Good - may need refinement), 50-69% (Acceptable - consider splitting), <50% (Needs Work - too vague)
Tag each skill with one of: helpful (contributed to success), harmful (caused failure), or neutral (no measurable impact)
When citing skills during implementation, use the format: Applying [Skill-ID], Strategy [description], Expected [outcome], Result [actual outcome], Skill Validated [yes/no]
Skills should be atomic learning statements of maximum 15 words
Skills must include measurable outcomes in the Impact field

**/*.md: Always specify language identifiers on fenc...

Files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md

⚙️ CodeRabbit configuration file

**/*.md: Writing Quality: - Grade 9 reading level - Active voice, direct address - Short sentences (under 15 words ideal) - No fluff, filler, or marketing language - Replace adjectives with data where possible - Every sentence must pass the "so what" test
Flag: - Passive voice - Vague language (nearly, some, almost, very) - Jargon without definitions - Broken links and outdated procedures - Inconsistency with code changes in same PR - Missing context for new features or APIs
Ignore (handled by .markdownlint-cli2.yaml): - Markdown formatting and style - Heading level choices - Link formatting variations - Minor punctuation preferences

Files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
**/AGENTS.md

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Update AGENTS.md documentation with Visual Studio 2026 repository-level installation instructions including agent file location '.github/agents/' and VS-specific usage examples

Files:

  • AGENTS.md
AGENTS.md

📄 CodeRabbit inference engine (.agents/planning/phase3-complete-handoff.md)

Document all artifact naming patterns and validation procedures in AGENTS.md under 'Naming Conventions' section with examples and references to automation tooling

Refer to AGENTS.md for complete project instructions and maintain all canonical agent documentation there following the DRY principle

Files:

  • AGENTS.md
**/*.{md,markdown}

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-17-session-failures.md)

Do not include auto-generated headers in generated files

Files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
scripts/lib/Config.psd1

📄 CodeRabbit inference engine (.agents/planning/cva-install-scripts.md)

scripts/lib/Config.psd1: Consolidate environment and scope-specific configuration into a PowerShell data file (Config.psd1) containing: source directories, file patterns, destination paths (as scriptblocks for dynamic resolution), instructions file names, and known bugs by environment
Use agent file patterns specific to each environment: *.md for Claude, *.agent.md for Copilot CLI and VSCode, ensuring only files matching the pattern are installed
For Copilot CLI global installation, include a warning about known issue #452 (user-level agents not being loaded) and provide guidance on workarounds if available

Files:

  • scripts/lib/Config.psd1
**/*.psd1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Use $ExecutionContext.InvokeCommand.ExpandString() for evaluating path expressions in PowerShell data files instead of raw variables

Files:

  • scripts/lib/Config.psd1
**/Config.psd1

📄 CodeRabbit inference engine (.agents/planning/PRD-visual-studio-install-support.md)

Add 'VisualStudio' environment entry to Config.psd1 with DisplayName, SourceDir, FilePattern, Global, and Repo configuration properties

Files:

  • scripts/lib/Config.psd1
**/CLAUDE.md

📄 CodeRabbit inference engine (.agents/governance/agent-consolidation-process.md)

Update the agent catalog (CLAUDE.md) to remove deprecated agents and reflect consolidated agent capabilities

Add reference to naming conventions and link to .agents/governance/naming-conventions.md in main agent documentation (CLAUDE.md)

Files:

  • CLAUDE.md
CLAUDE.md

📄 CodeRabbit inference engine (.agents/governance/steering-committee-charter.md)

Agent catalog table must be maintained in CLAUDE.md

Update CLAUDE.md to reference central naming conventions document at .agents/governance/naming-conventions.md for sequenced artifact patterns, type-prefixed patterns, and naming rules.

Files:

  • CLAUDE.md
scripts/install.ps1

📄 CodeRabbit inference engine (.agents/planning/cva-install-scripts.md)

scripts/install.ps1: Create a unified PowerShell install entry point (install.ps1) that accepts parameters -Environment [Claude|Copilot|VSCode], -Scope [Global|Local], and -RepoPath to support both local and remote installation via iex execution
Support remote PowerShell execution via iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/rjmurillo/ai-agents/main/scripts/install.ps1')) by detecting remote execution context, downloading dependencies to temp directory, and providing interactive prompts when parameters are not specified
Implement parameter validation in install scripts to ensure -Environment parameter accepts only: Claude, Copilot, VSCode; -Scope is either Global or Local (derived from parameter set); and -RepoPath is provided when not using Global scope

Files:

  • scripts/install.ps1
**/install.ps1

📄 CodeRabbit inference engine (.agents/retrospective/2025-12-15-cva-install-scripts.md)

Detect remote execution context via empty $PSScriptRoot and download dependencies to $env:TEMP for Invoke-Expression scenarios

**/install.ps1: Update install.ps1 ValidateSet parameter to include 'VisualStudio' alongside existing 'Claude', 'Copilot', and 'VSCode' options
Add 'Visual Studio 2026' option to the interactive menu in install.ps1 as item 4, maintaining consistent formatting with existing environment options
Deploy agents to '.github/agents/' directory for repository-level Visual Studio installation, reusing VS Code agent source from 'src/vs-code-agents'
Deploy instructions to '.github/' directory with filename 'copilot-instructions.md' for repository-level Visual Studio installation
Repository-level installation must copy all *.agent.md files from SourceDir to '.github/agents/' destination directory
Support '-Force' parameter in install.ps1 to overwrite existing agent and instruction files when specified

Files:

  • scripts/install.ps1
scripts/*.ps1

📄 CodeRabbit inference engine (.agents/pr-comments/PR-52/summary.md)

PowerShell error handling must use direct exit 1 statements instead of conditional if ($PassThru) { return $false } patterns to ensure proper exit code propagation in error paths

Files:

  • scripts/install.ps1
**/docs/**/*.md

📄 CodeRabbit inference engine (.agents/skills/documentation.md)

Structure requirements documents with Purpose, Configuration, Required Rules, Disabled Rules, Common Patterns, Troubleshooting, and References sections

Files:

  • docs/installation.md
docs/**/*.md

📄 CodeRabbit inference engine (docs/markdown-linting.md)

docs/**/*.md: Every fenced code block must include a language identifier
Fenced code blocks must be surrounded by blank lines
Lists must be surrounded by blank lines
Headings must be surrounded by blank lines
Inline HTML is restricted; generic types must be wrapped in backticks to avoid being interpreted as HTML tags
Use appropriate language identifiers for code blocks: 'csharp' for C#, 'powershell' for PowerShell, 'bash' for Bash/Shell, 'json' for JSON, 'yaml' for YAML, 'markdown' for Markdown examples, 'text' for plain text/pseudo-code, 'sql' for SQL, 'xml' or 'html' for XML/HTML, 'javascript' for JavaScript, 'typescript' for TypeScript, 'python' for Python
Exclude node_modules/ and .agents/ directories from markdown linting

Create dedicated documentation pages for significant features, including installation guides with parameters and usage examples

Files:

  • docs/installation.md
🧠 Learnings (8)
📚 Learning: 2025-12-18T02:19:41.405Z
Learnt from: CR
Repo: rjmurillo/ai-agents PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-18T02:19:41.405Z
Learning: Applies to src/claude/**/*.md : Claude Code agent files should be installed globally to ~/.claude/agents/ or per-repository to .claude/agents/, restarting Claude Code after installation

Applied to files:

  • AGENTS.md
📚 Learning: 2025-12-16T06:26:21.783Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/qa.shared.md:1-311
Timestamp: 2025-12-16T06:26:21.783Z
Learning: In the rjmurillo/ai-agents repository, follow the project's Markdown lint rules defined in .markdownlint-cli2.yaml. Do not flag MD031/MD032 (blank lines around fences) or similar style issues in Markdown files if the repository's markdownlint configuration passes; rely on the config to determine formatting and style decisions.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T06:26:44.230Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/implementer.shared.md:33-40
Timestamp: 2025-12-16T06:26:44.230Z
Learning: In the rjmurillo/ai-agents repository, markdownlint issues should be governed by the repository's .markdownlint-cli2.yaml configuration. Do not flag or enforce markdown formatting/style violations that are not surfaced by the configured rules. Apply this rule to all Markdown files (e.g., templates/agents/implementer.shared.md and others) and only flag issues that the project's markdownlint config would detect.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T06:26:44.208Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/planner.shared.md:73-121
Timestamp: 2025-12-16T06:26:44.208Z
Learning: In this repository (rjmurillo/ai-agents), do not flag Markdown formatting or style issues (MD031, MD032, heading levels, link formatting, punctuation) for Markdown files. These are already ignored by the project’s .markdownlint-cli2.yaml; rely on that configuration and the repository's coding guidelines for Markdown handling.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T06:27:04.317Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: src/copilot-cli/analyst.agent.md:39-44
Timestamp: 2025-12-16T06:27:04.317Z
Learning: In the rjmurillo/ai-agents repository, do not flag MD031 (blank lines around fenced code blocks) or MD032 (blank lines around lists) violations in Markdown files. These formatting rules are configured in the project’s .markdownlint-cli2.yaml, and such style issues do not affect agent instruction functionality. Apply this pattern to all Markdown files (recursively) and focus review attention on issues that affect behavior, correctness, or other lint rules.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T08:00:20.752Z
Learnt from: rjmurillo
Repo: rjmurillo/ai-agents PR: 43
File: templates/agents/roadmap.shared.md:124-174
Timestamp: 2025-12-16T08:00:20.752Z
Learning: Review Markdown files to ensure nested code fences follow the rule: the outer fence uses more backticks than the inner fence (e.g., an outer `````` with four backticks containing an inner ```mermaid``` fence). This follows CommonMark conventions; verify that nesting does not break rendering by using a greater number of backticks for the outer fence than the inner one.

Applied to files:

  • AGENTS.md
  • CLAUDE.md
  • docs/installation.md
📚 Learning: 2025-12-16T01:14:43.697Z
Learnt from: CR
Repo: rjmurillo/ai-agents PR: 0
File: docs/installation.md:0-0
Timestamp: 2025-12-16T01:14:43.697Z
Learning: Installation paths are platform-specific: Claude Code uses `~/.claude/agents`, Copilot CLI uses `~/.copilot/agents`, VS Code uses `%APPDATA%/Code/User/prompts` (Windows) or `~/.config/Code/User/prompts` (macOS/Linux)

Applied to files:

  • docs/installation.md
📚 Learning: 2025-12-16T01:14:43.697Z
Learnt from: CR
Repo: rjmurillo/ai-agents PR: 0
File: docs/installation.md:0-0
Timestamp: 2025-12-16T01:14:43.697Z
Learning: Applies to docs/.github/agents/** : For Copilot CLI and VS Code repository installations, commit changes to `.github/agents` directory and `.agents` artifact directory with message: `git add .github/agents .agents && git commit -m 'feat: add Copilot agent system'`

Applied to files:

  • docs/installation.md
🪛 GitHub Actions: Validate Path Normalization
AGENTS.md

[error] 132-132: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 132)


[error] 140-140: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 140)


[error] 162-162: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 162)


[error] 944-944: macOS User Path violation detected. Content references a macOS user home path; should use a relative path instead. (Line 944)


[error] 944-944: Linux Home Path violation detected. Content references a Linux user home path; should use a relative path instead. (Line 944)

docs/installation.md

[error] 35-35: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 35)


[error] 47-47: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 47)


[error] 68-68: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 68)


[error] 72-72: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 72)


[error] 76-76: Windows Absolute Path violation detected. Content contains a Windows drive letter path; should use a relative path instead. (Line 76)

🪛 LanguageTool
docs/installation.md

[uncategorized] ~94-~94: The official name of this software platform is spelled with a capital “H”.
Context: ...LAUDE.md(repo root) | | Copilot CLI |.github/agents/| (same directory) |.github/...

(GITHUB)


[uncategorized] ~94-~94: The official name of this software platform is spelled with a capital “H”.
Context: ... .github/agents/ | (same directory) | .github/copilot-instructions.md | | VS Code | ...

(GITHUB)


[uncategorized] ~95-~95: The official name of this software platform is spelled with a capital “H”.
Context: .../copilot-instructions.md| | VS Code |.github/agents/| (same directory) |.github/...

(GITHUB)


[uncategorized] ~95-~95: The official name of this software platform is spelled with a capital “H”.
Context: ... .github/agents/ | (same directory) | .github/copilot-instructions.md | ### .agents...

(GITHUB)

🔍 Remote MCP DeepWiki

Below is additional context relevant to reviewing PR #58 (“feat(installer): add command and prompt file installation support”) drawn from the repo’s DeepWiki documentation and code search.

– DeepWiki’s “Installation Module Architecture” page shows how the unified installer is structured:
• Config.psd1 defines per-scope Keys (InstructionsDest, plus new CommandsDir/CommandFiles and PromptFiles) that feed into Get-InstallConfig.
• scripts/lib/Install-Common.psm1 exposes Install-InstructionsFile (existing), Install-CommandFiles, and Install-PromptFiles, wiring them together in scripts/install.ps1’s main flow.
• A sequence diagram illustrates: load config → Install-InstructionsFile → (if CommandsDir) Install-CommandFiles → (if PromptFiles) Install-PromptFiles → summary output.

– In scripts/lib/Install-Common.psm1, code search shows:
• Install-CommandFiles (lines 110–165) accepts a CommandsDir path and CommandFiles array, iterates each file, creates target directories, copies with overwrite logic, and returns a hashtable of Installed/Updated/Skipped counts.
• Install-PromptFiles (lines 170–230) similarly transforms each source “.agent.md” into “.prompt.md” in the configured PromptFiles path, with the same stats hashtable pattern.
• Get-InstallConfig (around line 45) now appends three new entries—CommandsDir, CommandFiles, PromptFiles—into the merged configuration object returned to install.ps1.

– In scripts/install.ps1, code search reveals the integration points (around line 75):
• After copying core agent files, if the config object’s CommandsDir is non-empty, it invokes Install-CommandFiles and prints “Commands: Installed/Updated/Skipped”.
• Likewise, if PromptFiles is defined, it calls Install-PromptFiles and prints “Prompts: Installed/Updated/Skipped”.
• Existing logic for instructions file installation remains unchanged.

This additional context confirms that the PR’s new installer functions are correctly wired into the existing pipeline and that their parameters and return values align with the established pattern for Install-InstructionsFile.

🔇 Additional comments (33)
.github/instructions/testing.instructions.md (1)

12-12: LGTM - Improved formatting and useful testing guidance.

The blank lines comply with MD032, and the new principles (coverage target and Mock usage) are standard best practices.

Also applies to: 24-29

.github/instructions/agent-prompts.instructions.md (1)

12-12: LGTM - Formatting improvement.

Blank lines added for MD032 compliance with no content changes.

Also applies to: 23-23, 29-29

.github/instructions/security.instructions.md (1)

12-22: LGTM - Comprehensive security guidance expansion.

The additions cover:

  • Complete OWASP Top 10 coverage
  • Detailed critical patterns for auth, secrets, input validation, and output encoding
  • File path triggers for mandatory security review
  • Full STRIDE threat model

All align with security best practices and coding guidelines.

Also applies to: 27-51, 53-71

AGENTS.md (2)

360-368: LGTM - File types documentation is clear and accurate.

The new sections consistently document agent files, prompt files, and command files across all platforms (VS Code, Copilot CLI, Claude) with clear pattern explanations.

Also applies to: 401-409, 434-447


452-454: LGTM - Updated Claude notes reflect new command file support.

The notes now correctly mention slash commands and override behavior.

scripts/lib/Config.psd1 (2)

39-43: LGTM - Claude command configuration follows established pattern.

CommandsDir and CommandFiles added consistently for both Global and Repo scopes, matching the existing configuration structure.

Also applies to: 49-53


71-74: LGTM - Prompt file configuration consistent across platforms.

PromptFiles arrays added for Copilot and VSCode in both Global and Repo scopes. Structure aligns with existing patterns.

Also applies to: 80-83, 96-99, 105-108

CLAUDE.md (1)

22-47: LGTM - Mandatory session protocol addresses amnesia problem.

The new section clearly establishes non-negotiable requirements for session continuity with minimal checklist and proper AGENTS.md cross-reference. The "expert amnesiac" framing effectively communicates the issue.

.github/copilot-instructions.md (1)

24-49: LGTM - Consistent session protocol for Copilot.

The mandatory session protocol section mirrors CLAUDE.md with correct relative path to AGENTS.md. Maintains consistency across platforms.

scripts/tests/install.Tests.ps1 (1)

188-222: LGTM - Test coverage for new command and prompt installation.

The new test contexts verify integration of Install-CommandFiles and Install-PromptFiles functions, configuration checks, path resolution, and output messaging. Pattern matches existing tests.

scripts/install.ps1 (2)

328-343: LGTM! Command installation logic is solid.

The conditional checks and path resolution follow the established pattern. Stats reporting is consistent with existing flow.


345-358: LGTM! Prompt file installation correctly reuses agent destination.

No separate path resolution needed since prompt files are generated alongside agent files in the same directory.

scripts/tests/Config.Tests.ps1 (6)

136-148: Comprehensive test coverage for Claude command configuration.

Tests validate presence, pattern matching, and expected file contents.


165-176: LGTM! Repo scope command tests mirror global scope pattern.


229-236: LGTM! Copilot prompt file configuration tests look good.


252-259: LGTM! Repo scope matches global pattern.


295-302: LGTM! VSCode global prompt tests follow established pattern.


318-325: LGTM! VSCode repo tests complete comprehensive coverage.

All environments (Claude, Copilot, VSCode) and scopes (Global, Repo) now have test coverage for the new configuration fields.

scripts/lib/Install-Common.psm1 (4)

78-80: LGTM! Configuration field additions follow existing pattern.

The three new fields (CommandsDir, CommandFiles, PromptFiles) are exposed via the merged configuration object, consistent with existing fields like InstructionsFile.


376-454: LGTM! Install-CommandFiles implementation is solid.

The function follows established patterns from Copy-AgentFile:

  • Creates destination directory if needed
  • Handles missing source files gracefully (warns, continues)
  • Prompts before overwriting unless -Force is specified
  • Returns consistent stats hashtable

Error handling and user interaction are appropriate.


456-532: LGTM! Install-PromptFiles correctly transforms agent files to prompts.

Key implementation details:

  • Transforms .agent.md.prompt.md using regex replacement (line 511)
  • Reuses existing agent destination directory (doesn't create separately)
  • Follows same error handling and prompting patterns as Install-CommandFiles

The regex pattern '\.agent\.md$' correctly anchors at end and escapes dots.


757-758: LGTM! Module exports updated correctly.

Both new functions are exposed as part of the public API.

docs/installation.md (6)

83-87: LGTM! Global paths table accurately reflects new file types.

The restructured table clearly shows where agents and commands/prompts are installed for each environment.


91-95: LGTM! Repository paths table includes new command/prompt locations.


115-133: Excellent addition! Clarifies what files are installed and why.

The explanation of file types, extensions, and the auto-generation of prompt files helps users understand the installation artifacts.


258-258: LGTM! Commit command updated to include instructions file.


270-271: LGTM! Uninstall commands include new directories.


284-285: LGTM! Repository cleanup includes new command directories.

scripts/tests/Install-Common.Tests.ps1 (5)

62-87: LGTM! Configuration tests validate CommandsDir and CommandFiles.

Tests cover both Global and Repo scopes with appropriate assertions (pattern matching for Global, exact paths for Repo).


110-122: LGTM! Copilot PromptFiles configuration tests look good.


143-155: LGTM! VSCode PromptFiles tests complete the coverage.


496-575: Excellent test coverage for Install-CommandFiles.

Tests cover:

  • Directory creation
  • Single and multiple file installation
  • Update scenarios with -Force
  • Error handling (missing source files)
  • Partial success when some files are missing

Test isolation using BeforeEach ensures clean state. Stats validation confirms correct counting.


577-651: Excellent test coverage for Install-PromptFiles.

Tests verify critical behavior:

  • Name transformation (.agent.md.prompt.md)
  • Confirmation that source filename is NOT used in destination (line 605)
  • Multiple file handling
  • Update scenarios
  • Error handling for missing files

The transformation verification on lines 604-605 is particularly important - confirms files are transformed, not duplicated.

coderabbitai[bot]
coderabbitai Bot previously approved these changes Dec 18, 2025
@rjmurillo rjmurillo merged commit 8d62193 into main Dec 18, 2025
5 of 8 checks passed
@rjmurillo rjmurillo deleted the feat/pr-comment-responder-command branch December 18, 2025 06:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants