.github/skills/context-multi-file/SKILL.md
Context Architect pattern for autonomous multi-file changes. Plans and executes coordinated changes across multiple files by mapping dependencies, identifying impact, and applying changes in correct order. Use when refactoring, renaming, or implementing features that span multiple files.
npx skillsauth add javiertarazon/agente-copilot context-multi-fileInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Plan and execute coordinated changes across multiple files while respecting dependencies and avoiding conflicts. Based on the Context Architect agent from github/awesome-copilot.
1. SCAN — Map all files that need changing
2. ANALYZE — Build dependency graph, find change order
3. PLAN — Create ordered change manifest
4. EXECUTE — Apply changes bottom-up (leaves first)
5. VALIDATE — Verify nothing broke
Identify all affected files:
Query: "Where is UserService used?"
→ src/controllers/user.controller.ts
→ src/routes/user.routes.ts
→ src/middleware/auth.middleware.ts
→ tests/unit/user.controller.spec.ts
→ tests/integration/user.flow.spec.ts
→ src/admin/user.admin.ts
Categories of changes: | Type | Description | |------|-------------| | Direct | File contains the thing being changed | | Import | File imports from changed module | | Type | File uses the changed type/interface | | Test | File tests the changed code | | Config | File references via string (routes, config) |
Build a dependency graph to determine change order:
UserService (CORE — change first)
↑ imported by
├── auth.middleware.ts (depends on UserService)
├── user.controller.ts (depends on UserService)
│ ↑ imported by
│ └── user.routes.ts (depends on controller)
└── admin/user.admin.ts (depends on UserService)
↑ imported by
└── admin/routes.ts
Tests (change last — after production code):
├── user.controller.spec.ts
└── user.flow.spec.ts
Change order (bottom-up):
UserService (core)auth.middleware.ts, user.admin.ts (direct dependents)user.controller.ts (depends on middleware)user.routes.ts, admin/routes.ts (top-level)Create a detailed change manifest:
change_manifest:
goal: "Add pagination to UserService.getAll()"
changes:
- file: src/services/user.service.ts
type: modify
changes:
- "Add PaginationOptions parameter to getAll()"
- "Return PaginatedResult<User> instead of User[]"
- "Add corresponding method to IUserService interface"
- file: src/controllers/user.controller.ts
type: modify
depends_on: [user.service.ts]
changes:
- "Extract page/limit from query params"
- "Pass PaginationOptions to service.getAll()"
- "Return paginated response with metadata"
- file: src/models/pagination.model.ts
type: create
changes:
- "Create PaginationOptions interface"
- "Create PaginatedResult<T> generic interface"
- file: tests/unit/user.controller.spec.ts
type: modify
depends_on: [user.controller.ts]
changes:
- "Update mock for service.getAll() to return PaginatedResult"
- "Add tests for pagination parameters"
Apply changes in dependency order:
git stash # or git commit --allow-empty -m "checkpoint: before multi-file change"
Error in user.controller.ts: Type 'User[]' not assignable to 'PaginatedResult<User>'
→ Re-read change manifest
→ Was pagination.model.ts created successfully?
→ Was user.service.ts updated first?
→ Fix the dependency, retry
After all changes applied:
# TypeScript
npx tsc --noEmit
# Linting
npx eslint src/ --ext .ts
# Tests
npx jest --no-coverage
# If API project:
# Start server and run smoke tests
Expected output:
✅ TypeScript: 0 errors
✅ ESLint: 0 warnings
✅ Tests: 47 passed, 0 failed
✅ New tests added: 3
1. Find all usages (grep/LSP)
2. Update declaration
3. Update all references (alphabetical by file)
4. Run tests
1. Create new interface file
2. Add interface to existing class
3. Update all injection points to use interface
4. Update tests to mock interface
1. Add parameter with default value (backward compatible)
2. Update all callers to pass explicit value
3. Remove default value (make it required)
4. Verify no callers missed
agent-orchestration — Context Architect is the planning sub-agentcode-refactoring-refactor-clean for the actual refactoring logicpolyglot-testing-pipeline to update tests after multi-file changestdd-full-cycle when the multi-file change is feature-driventools
Automate GitHub repositories, issues, pull requests, branches, CI/CD, and permissions via Rube MCP (Composio). Manage code workflows, review PRs, search code, and handle deployments programmatically.
development
Create production-ready GitHub Actions workflows for automated testing, building, and deploying applications. Use when setting up CI/CD with GitHub Actions, automating development workflows, or cre...
tools
Stage, commit, and push git changes with conventional commit messages. Use when user wants to commit and push changes, mentions pushing to remote, or asks to save and push their work. Also activate...
development
You are a PR optimization expert specializing in creating high-quality pull requests that facilitate efficient code reviews. Generate comprehensive PR descriptions, automate review processes, and ensu