import { z } from "zod";
/**
* Project Tracker Tool
* Tracks project structure, files, and architecture
*/
export const trackProjectSchema = {
name: "track_project",
description: "Analyzes and tracks project structure, keeping inventory of all files, folders, and their purposes. Use at project start and after major changes.",
inputSchema: z.object({
projectPath: z.string().describe("Root path of the project"),
projectName: z.string().describe("Name of the project"),
techStack: z.array(z.string()).optional().describe("Technologies used")
})
};
export function trackProjectHandler(args: any) {
const { projectPath, projectName, techStack = [] } = args;
let tracking = "# Project Tracking: " + projectName + "\n\n";
tracking += "## Project Root\n";
tracking += "`" + projectPath + "`\n\n";
tracking += "## Tech Stack\n";
if (techStack.length > 0) {
tracking += techStack.map((t: string) => "- " + t).join("\n");
} else {
tracking += "Not specified";
}
tracking += "\n\n---\n\n";
tracking += "## Recommended Structure\n\n";
tracking += "### For Web Projects\n";
tracking += "```\n";
tracking += projectName + "/\n";
tracking += "βββ src/ # Source code\n";
tracking += "β βββ components/ # UI components\n";
tracking += "β βββ pages/ # Page components\n";
tracking += "β βββ hooks/ # Custom hooks\n";
tracking += "β βββ utils/ # Utility functions\n";
tracking += "β βββ services/ # API services\n";
tracking += "β βββ types/ # TypeScript types\n";
tracking += "β βββ styles/ # Global styles\n";
tracking += "βββ public/ # Static assets\n";
tracking += "βββ tests/ # Test files\n";
tracking += "βββ docs/ # Documentation\n";
tracking += "βββ .github/ # GitHub config\n";
tracking += "β βββ workflows/ # GitHub Actions\n";
tracking += "βββ package.json\n";
tracking += "βββ tsconfig.json\n";
tracking += "βββ README.md\n";
tracking += "βββ .gitignore\n";
tracking += "```\n\n";
tracking += "### For API Projects\n";
tracking += "```\n";
tracking += projectName + "/\n";
tracking += "βββ src/\n";
tracking += "β βββ controllers/ # Route handlers\n";
tracking += "β βββ services/ # Business logic\n";
tracking += "β βββ models/ # Data models\n";
tracking += "β βββ middleware/ # Custom middleware\n";
tracking += "β βββ routes/ # Route definitions\n";
tracking += "β βββ utils/ # Helpers\n";
tracking += "β βββ config/ # Configuration\n";
tracking += "βββ tests/\n";
tracking += "βββ migrations/ # Database migrations\n";
tracking += "βββ docs/\n";
tracking += "βββ docker-compose.yml\n";
tracking += "```\n\n";
tracking += "## File Tracking Checklist\n";
tracking += "- [ ] README.md - Project documentation\n";
tracking += "- [ ] package.json - Dependencies & scripts\n";
tracking += "- [ ] .gitignore - Git ignore patterns\n";
tracking += "- [ ] .env.example - Environment template\n";
tracking += "- [ ] tsconfig.json - TypeScript config\n";
tracking += "- [ ] Dockerfile - Container definition\n";
tracking += "- [ ] docker-compose.yml - Container orchestration\n\n";
tracking += "## Best Practices\n";
tracking += "1. Keep related files together (feature-based)\n";
tracking += "2. Separate concerns (logic, UI, data)\n";
tracking += "3. Use consistent naming conventions\n";
tracking += "4. Document as you go\n";
tracking += "5. Track all new files added\n";
return { content: [{ type: "text", text: tracking }] };
}
/**
* Check Dependencies Tool
* Monitors dependencies for issues
*/
export const checkDependenciesSchema = {
name: "check_dependencies",
description: "Analyzes project dependencies for security vulnerabilities, deprecations, and outdated packages. Essential for maintaining healthy projects.",
inputSchema: z.object({
packageManager: z.enum(["npm", "yarn", "pnpm", "pip", "cargo"]).describe("Package manager to check"),
packageFile: z.string().optional().describe("Path to package file (package.json, requirements.txt, etc.)")
})
};
export function checkDependenciesHandler(args: any) {
const { packageManager } = args;
const commands: Record<string, { audit: string; outdated: string; update: string }> = {
npm: {
audit: "npm audit",
outdated: "npm outdated",
update: "npm update"
},
yarn: {
audit: "yarn audit",
outdated: "yarn outdated",
update: "yarn upgrade"
},
pnpm: {
audit: "pnpm audit",
outdated: "pnpm outdated",
update: "pnpm update"
},
pip: {
audit: "pip-audit",
outdated: "pip list --outdated",
update: "pip install --upgrade"
},
cargo: {
audit: "cargo audit",
outdated: "cargo outdated",
update: "cargo update"
}
};
const cmds = commands[packageManager];
let check = "# Dependency Health Check\n\n";
check += "## Package Manager: " + packageManager + "\n\n";
check += "---\n\n";
check += "## Commands to Run\n\n";
check += "### 1. Security Audit\n";
check += "```bash\n";
check += cmds.audit + "\n";
check += "```\n";
check += "Checks for known vulnerabilities in dependencies.\n\n";
check += "### 2. Check Outdated\n";
check += "```bash\n";
check += cmds.outdated + "\n";
check += "```\n";
check += "Lists packages with newer versions available.\n\n";
check += "### 3. Update Dependencies\n";
check += "```bash\n";
check += cmds.update + "\n";
check += "```\n";
check += "Updates to latest compatible versions.\n\n";
check += "---\n\n";
check += "## Dependency Best Practices\n\n";
check += "### Security\n";
check += "- [ ] Run audit before every release\n";
check += "- [ ] Enable Dependabot/Renovate for automatic updates\n";
check += "- [ ] Review changelogs before major updates\n";
check += "- [ ] Pin versions in production\n\n";
check += "### Maintenance\n";
check += "- [ ] Update dependencies monthly\n";
check += "- [ ] Remove unused dependencies\n";
check += "- [ ] Avoid deprecated packages\n";
check += "- [ ] Lock file committed to git\n\n";
check += "### Automated Tools\n";
check += "- **Snyk**: Free security scanning\n";
check += "- **Dependabot**: Auto-update PRs\n";
check += "- **Renovate**: Advanced dependency management\n";
check += "- **npm-check**: Interactive updates\n\n";
check += "## Docker Security Scanning\n";
check += "```bash\n";
check += "docker scout cves <image> # Scan for vulnerabilities\n";
check += "docker scout quickview <image> # Quick security overview\n";
check += "docker scout recommendations # Get fix recommendations\n";
check += "```\n\n";
check += "## GitHub Actions Integration\n";
check += "Add to `.github/workflows/security.yml`:\n";
check += "```yaml\n";
check += "name: Security Scan\n";
check += "on: [push, pull_request]\n";
check += "jobs:\n";
check += " audit:\n";
check += " runs-on: ubuntu-latest\n";
check += " steps:\n";
check += " - uses: actions/checkout@v4\n";
check += " - run: npm audit --audit-level=high\n";
check += "```\n";
return { content: [{ type: "text", text: check }] };
}
/**
* Generate GitHub Actions Tool
* Creates CI/CD workflows
*/
export const generateGitHubActionsSchema = {
name: "generate_github_actions",
description: "Generates GitHub Actions workflow files for CI/CD, testing, security scanning, and deployment.",
inputSchema: z.object({
projectType: z.enum(["node", "python", "rust", "go", "docker"]).describe("Type of project"),
features: z.array(z.enum(["test", "lint", "build", "deploy", "security", "release"])).describe("Features to include")
})
};
export function generateGitHubActionsHandler(args: any) {
const { projectType, features } = args;
const workflows: string[] = [];
if (features.includes("test") || features.includes("lint") || features.includes("build")) {
const ciSteps = [];
if (projectType === "node") {
ciSteps.push(" - uses: actions/checkout@v4");
ciSteps.push(" - uses: actions/setup-node@v4");
ciSteps.push(" with:");
ciSteps.push(" node-version: '20'");
ciSteps.push(" cache: 'npm'");
ciSteps.push(" - run: npm ci");
if (features.includes("lint")) ciSteps.push(" - run: npm run lint");
if (features.includes("test")) ciSteps.push(" - run: npm test");
if (features.includes("build")) ciSteps.push(" - run: npm run build");
} else if (projectType === "python") {
ciSteps.push(" - uses: actions/checkout@v4");
ciSteps.push(" - uses: actions/setup-python@v5");
ciSteps.push(" with:");
ciSteps.push(" python-version: '3.12'");
ciSteps.push(" - run: pip install -r requirements.txt");
if (features.includes("lint")) ciSteps.push(" - run: ruff check .");
if (features.includes("test")) ciSteps.push(" - run: pytest");
}
workflows.push("# .github/workflows/ci.yml\n" +
"name: CI\n" +
"on:\n" +
" push:\n" +
" branches: [main]\n" +
" pull_request:\n" +
" branches: [main]\n\n" +
"jobs:\n" +
" build:\n" +
" runs-on: ubuntu-latest\n" +
" steps:\n" +
ciSteps.join("\n"));
}
if (features.includes("security")) {
workflows.push("# .github/workflows/security.yml\n" +
"name: Security Scan\n" +
"on:\n" +
" push:\n" +
" branches: [main]\n" +
" schedule:\n" +
" - cron: '0 0 * * 0' # Weekly\n\n" +
"jobs:\n" +
" security:\n" +
" runs-on: ubuntu-latest\n" +
" steps:\n" +
" - uses: actions/checkout@v4\n" +
" - name: Run security audit\n" +
" run: " + (projectType === "node" ? "npm audit --audit-level=high" : projectType === "python" ? "pip-audit" : "cargo audit") + "\n" +
" - name: Dependency review\n" +
" uses: actions/dependency-review-action@v4\n" +
" if: github.event_name == 'pull_request'");
}
let result = "# GitHub Actions Workflows\n\n";
result += "## Generated Workflows for " + projectType + "\n\n";
result += workflows.join("\n\n---\n\n");
result += "\n\n---\n\n";
result += "## Additional Recommended Workflows\n\n";
result += "### Dependabot Config\n";
result += "Create `.github/dependabot.yml`:\n";
result += "```yaml\n";
result += "version: 2\n";
result += "updates:\n";
result += " - package-ecosystem: \"" + (projectType === "node" ? "npm" : projectType === "python" ? "pip" : projectType) + "\"\n";
result += " directory: \"/\"\n";
result += " schedule:\n";
result += " interval: \"weekly\"\n";
result += " open-pull-requests-limit: 10\n";
result += "```\n\n";
result += "### Branch Protection\n";
result += "Enable in GitHub Settings:\n";
result += "- Require PR reviews\n";
result += "- Require status checks (CI must pass)\n";
result += "- Require up-to-date branches\n";
return { content: [{ type: "text", text: result }] };
}
/**
* Full Stack Scaffold Tool
* Creates complete project structures
*/
export const fullStackScaffoldSchema = {
name: "full_stack_scaffold",
description: "Generates a complete full-stack project structure with all necessary files and configurations. One command to create a production-ready project.",
inputSchema: z.object({
projectName: z.string().describe("Name of the project"),
frontend: z.enum(["react", "vue", "svelte", "next", "none"]).describe("Frontend framework"),
backend: z.enum(["express", "fastapi", "django", "nestjs", "none"]).describe("Backend framework"),
database: z.enum(["postgresql", "mongodb", "sqlite", "none"]).describe("Database"),
features: z.array(z.string()).optional().describe("Additional features")
})
};
export function fullStackScaffoldHandler(args: any) {
const { projectName, frontend, backend, database, features = [] } = args;
let scaffold = "# Full Stack Scaffold: " + projectName + "\n\n";
scaffold += "## Stack Configuration\n";
scaffold += "- **Frontend**: " + frontend + "\n";
scaffold += "- **Backend**: " + backend + "\n";
scaffold += "- **Database**: " + database + "\n";
scaffold += "- **Features**: " + (features.join(", ") || "Standard") + "\n\n";
scaffold += "---\n\n";
scaffold += "## Project Structure\n\n";
scaffold += "```\n";
scaffold += projectName + "/\n";
scaffold += "βββ frontend/ # " + (frontend !== "none" ? frontend.toUpperCase() + " App" : "N/A") + "\n";
if (frontend !== "none") {
scaffold += "β βββ src/\n";
scaffold += "β βββ public/\n";
scaffold += "β βββ package.json\n";
scaffold += "β βββ vite.config.ts\n";
}
scaffold += "βββ backend/ # " + (backend !== "none" ? backend.toUpperCase() + " API" : "N/A") + "\n";
if (backend !== "none") {
scaffold += "β βββ src/\n";
scaffold += "β β βββ controllers/\n";
scaffold += "β β βββ services/\n";
scaffold += "β β βββ models/\n";
scaffold += "β β βββ routes/\n";
scaffold += "β βββ tests/\n";
scaffold += "β βββ package.json\n";
}
scaffold += "βββ database/ # " + (database !== "none" ? database + " Config" : "N/A") + "\n";
if (database !== "none") {
scaffold += "β βββ migrations/\n";
scaffold += "β βββ seeds/\n";
}
scaffold += "βββ docker/\n";
scaffold += "β βββ Dockerfile.frontend\n";
scaffold += "β βββ Dockerfile.backend\n";
scaffold += "β βββ docker-compose.yml\n";
scaffold += "βββ .github/\n";
scaffold += "β βββ workflows/\n";
scaffold += "β βββ ci.yml\n";
scaffold += "β βββ deploy.yml\n";
scaffold += "βββ docs/\n";
scaffold += "β βββ api.md\n";
scaffold += "β βββ setup.md\n";
scaffold += "βββ .env.example\n";
scaffold += "βββ .gitignore\n";
scaffold += "βββ README.md\n";
scaffold += "βββ Makefile\n";
scaffold += "```\n\n";
scaffold += "## Setup Commands\n\n";
scaffold += "```bash\n";
scaffold += "# Create project\n";
scaffold += "mkdir " + projectName + " && cd " + projectName + "\n\n";
scaffold += "# Initialize\n";
if (frontend !== "none") {
scaffold += "npm create vite@latest frontend -- --template " + (frontend === "react" ? "react-ts" : frontend) + "\n";
}
if (backend === "express") {
scaffold += "mkdir backend && cd backend && npm init -y && npm i express typescript @types/express\n";
}
if (backend === "fastapi") {
scaffold += "mkdir backend && cd backend && python -m venv venv && pip install fastapi uvicorn\n";
}
scaffold += "\n# Database\n";
if (database === "postgresql") {
scaffold += "docker run -d --name postgres -e POSTGRES_PASSWORD=secret -p 5432:5432 postgres\n";
}
if (database === "mongodb") {
scaffold += "docker run -d --name mongo -p 27017:27017 mongo\n";
}
scaffold += "```\n\n";
scaffold += "## Docker Compose\n\n";
scaffold += "```yaml\n";
scaffold += "version: '3.8'\n";
scaffold += "services:\n";
if (frontend !== "none") {
scaffold += " frontend:\n";
scaffold += " build: ./docker/Dockerfile.frontend\n";
scaffold += " ports:\n";
scaffold += " - \"3000:3000\"\n";
scaffold += " depends_on:\n";
scaffold += " - backend\n";
}
if (backend !== "none") {
scaffold += " backend:\n";
scaffold += " build: ./docker/Dockerfile.backend\n";
scaffold += " ports:\n";
scaffold += " - \"8000:8000\"\n";
scaffold += " environment:\n";
scaffold += " - DATABASE_URL=${DATABASE_URL}\n";
}
if (database !== "none") {
scaffold += " database:\n";
scaffold += " image: " + database + "\n";
scaffold += " ports:\n";
scaffold += " - \"" + (database === "postgresql" ? "5432:5432" : database === "mongodb" ? "27017:27017" : "") + "\"\n";
scaffold += " volumes:\n";
scaffold += " - db_data:/var/lib/" + (database === "postgresql" ? "postgresql/data" : database === "mongodb" ? "mongodb" : "data") + "\n";
}
scaffold += "volumes:\n";
scaffold += " db_data:\n";
scaffold += "```\n\n";
scaffold += "## Next Steps\n";
scaffold += "1. [ ] Clone/create repository\n";
scaffold += "2. [ ] Set up environment variables\n";
scaffold += "3. [ ] Install dependencies\n";
scaffold += "4. [ ] Set up database\n";
scaffold += "5. [ ] Run development servers\n";
scaffold += "6. [ ] Configure CI/CD\n";
return { content: [{ type: "text", text: scaffold }] };
}
/**
* Developer Rules Tool
* Enforces best practices
*/
export const developerRulesSchema = {
name: "developer_rules",
description: "Provides comprehensive developer rules and checklists for maintaining high-quality, secure code.",
inputSchema: z.object({
category: z.enum(["security", "performance", "maintainability", "agent", "all"]).describe("Category of rules")
})
};
export function developerRulesHandler(args: any) {
const { category } = args;
let rules = "# Developer Rules & Best Practices\n\n";
rules += "## Category: " + category + "\n\n";
rules += "---\n\n";
if (category === "agent" || category === "all") {
rules += "## π€ Agentic & Tool Use Rules\n\n";
rules += "### Tool Preference Strategy\n";
rules += "- [ ] **ALWAYS** prefer Code-MCP tools over shell commands (run_command)\n";
rules += " - Use `list_files` instead of `ls` or `dir`\n";
rules += " - Use `search_files` instead of `grep` or `findstr`\n";
rules += " - Use `read_file_snippet` over `cat` for large files\n";
rules += "- [ ] **WHY?**\n";
rules += " - Tools are safer (sandboxed)\n";
rules += " - Tools return structured JSON (easier to parse)\n";
rules += " - Tools are OS-agnostic (works on Windows/Linux)\n\n";
rules += "### File Operations\n";
rules += "- [ ] Use `write_to_file` for new files\n";
rules += "- [ ] Use `replace_file_content` for edits (minimizes tokens)\n";
rules += "- [ ] verify file existence with `list_files` before reading\n\n";
rules += "### Thinking Process\n";
rules += "- [ ] Use `sequential_thinking` for complex tasks\n";
rules += "- [ ] Use `plan_task` before starting multi-step work\n";
rules += "- [ ] Use `project_profiler` when joining a new codebase\n\n";
}
if (category === "security" || category === "all") {
rules += "## π Security Rules\n\n";
rules += "### Dependencies\n";
rules += "- [ ] Run `npm audit` before every release\n";
rules += "- [ ] Enable automated security updates (Dependabot)\n";
rules += "- [ ] Never use deprecated packages\n";
rules += "- [ ] Review dependency changelogs before updating\n";
rules += "- [ ] Pin production dependencies to exact versions\n\n";
rules += "### Code Security\n";
rules += "- [ ] Validate ALL user inputs (server-side)\n";
rules += "- [ ] Use parameterized queries (prevent SQL injection)\n";
rules += "- [ ] Escape output (prevent XSS)\n";
rules += "- [ ] Implement proper authentication (OAuth, JWT)\n";
rules += "- [ ] Use HTTPS everywhere\n";
rules += "- [ ] Set security headers (CSP, HSTS, X-Frame-Options)\n\n";
rules += "### Secrets\n";
rules += "- [ ] NEVER commit secrets to git\n";
rules += "- [ ] Use environment variables\n";
rules += "- [ ] Rotate keys regularly\n";
rules += "- [ ] Use secret managers (Vault, AWS Secrets)\n\n";
rules += "### Docker Security\n";
rules += "- [ ] Scan images: `docker scout cves <image>`\n";
rules += "- [ ] Use official base images\n";
rules += "- [ ] Run as non-root user\n";
rules += "- [ ] Keep images minimal (Alpine)\n\n";
}
if (category === "performance" || category === "all") {
rules += "## β‘ Performance Rules\n\n";
rules += "### Code\n";
rules += "- [ ] Profile before optimizing\n";
rules += "- [ ] Use appropriate data structures\n";
rules += "- [ ] Avoid N+1 queries\n";
rules += "- [ ] Implement caching where appropriate\n";
rules += "- [ ] Lazy load heavy resources\n\n";
rules += "### Frontend\n";
rules += "- [ ] Bundle & minify assets\n";
rules += "- [ ] Optimize images (WebP, lazy loading)\n";
rules += "- [ ] Use CDN for static assets\n";
rules += "- [ ] Implement code splitting\n";
rules += "- [ ] Add proper caching headers\n\n";
rules += "### Backend\n";
rules += "- [ ] Use connection pooling\n";
rules += "- [ ] Implement request rate limiting\n";
rules += "- [ ] Add database indexes\n";
rules += "- [ ] Use async/await properly\n";
rules += "- [ ] Monitor memory usage\n\n";
}
if (category === "maintainability" || category === "all") {
rules += "## π§ Maintainability Rules\n\n";
rules += "### Code Quality\n";
rules += "- [ ] Follow language style guides\n";
rules += "- [ ] Use linters (ESLint, Pylint, etc.)\n";
rules += "- [ ] Write self-documenting code\n";
rules += "- [ ] Keep functions small (<50 lines)\n";
rules += "- [ ] DRY - Don't Repeat Yourself\n\n";
rules += "### Documentation\n";
rules += "- [ ] Maintain README.md\n";
rules += "- [ ] Document public APIs\n";
rules += "- [ ] Write clear commit messages\n";
rules += "- [ ] Create Architecture Decision Records\n\n";
rules += "### Testing\n";
rules += "- [ ] Write tests before/with code\n";
rules += "- [ ] Aim for >80% coverage\n";
rules += "- [ ] Test edge cases\n";
rules += "- [ ] Run tests in CI/CD\n\n";
rules += "### Git\n";
rules += "- [ ] Use feature branches\n";
rules += "- [ ] Write descriptive PRs\n";
rules += "- [ ] Review code before merging\n";
rules += "- [ ] Keep commits atomic\n\n";
}
rules += "---\n\n";
rules += "## Automated Enforcement\n\n";
rules += "### Pre-commit Hooks\n";
rules += "```bash\n";
rules += "npx husky install\n";
rules += "npx husky add .husky/pre-commit \"npm run lint && npm test\"\n";
rules += "```\n\n";
rules += "### CI/CD Checks\n";
rules += "- Lint on every push\n";
rules += "- Test on every PR\n";
rules += "- Security scan weekly\n";
rules += "- Dependency updates automated\n";
return { content: [{ type: "text", text: rules }] };
}
/**
* Enforce Project Standards Tool
* Checks project against defined standards
*/
export const enforceProjectStandardsSchema = {
name: "enforce_project_standards",
description: "Enforces project standards by checking for required files, running security audits, verifying test capability, and ensuring MCP tool usage.",
inputSchema: z.object({
fix: z.boolean().default(false).describe("Attempt to auto-fix issues (e.g., create missing files)"),
})
};
export function enforceProjectStandardsHandler(args: { fix?: boolean }) {
const { fix = false } = args;
let report = "# Project Standards Enforcement Report π‘οΈ\n\n";
report += "## π Automated Checks\n\n";
report += "### 1. Essential Files\n";
report += "| File | Status | Required Action |\n";
report += "|------|--------|-----------------|\n";
report += "| `README.md` | β Check | Create documentation |\n";
report += "| `package.json` | β Check | Initialize project |\n";
report += "| `.gitignore` | β Check | Add gitignore |\n";
report += "| `tsconfig.json` | β Check | Add TypeScript config |\n\n";
report += "### 2. Security & Quality\n";
report += "- [ ] **Dependency Audit**: Run `npm audit`\n";
report += "- [ ] **Linting**: Check if `eslint` is installed\n";
report += "- [ ] **Testing**: Check if `npm test` script exists\n";
report += "- [ ] **MCP Usage**: Ensure `.cursorrules` or `GEMINI.md` exists\n\n";
report += "## π οΈ Enforcement Script\n";
report += "Run this script to verify and fix standards:\n\n";
report += "```bash\n";
report += "#!/bin/bash\n";
report += "echo \"π‘οΈ Starting Code-MCP Enforcement...\"\n\n";
report += "# 1. Check Files\n";
report += "for file in README.md package.json .gitignore tsconfig.json; do\n";
report += " if [ -f \"$file\" ]; then\n";
report += " echo \"β
$file found\"\n";
report += " else\n";
report += " echo \"β $file MISSING\"\n";
report += " if [ \"" + fix + "\" = \"true\" ]; then\n";
report += " echo \" β¨ Creating $file...\"\n";
report += " touch $file\n";
report += " fi\n";
report += " fi\n";
report += "done\n\n";
report += "# 2. Check Security\n";
report += "if [ -f package.json ]; then\n";
report += " echo \"π Running npm audit...\"\n";
report += " npm audit --audit-level=high\n";
report += "else\n";
report += " echo \"β οΈ No package.json found, skipping audit\"\n";
report += "fi\n\n";
report += "# 3. Check MCP Configuration\n";
report += "if [ -f GEMINI.md ] || [ -f .cursorrules ]; then\n";
report += " echo \"β
MCP Configuration found\"\n";
report += "else\n";
report += " echo \"β MCP Configuration MISSING (GEMINI.md or .cursorrules)\"\n";
report += " echo \" π‘ Tip: Use 'mcp_generate_gemini_config' to create it.\"\n";
report += "fi\n\n";
report += "echo \"π Enforcement Complete\"\n";
report += "```\n\n";
report += "## π Recommended Actions\n";
report += "1. **Run the script above** in your terminal.\n";
report += "2. **Use Code-MCP Tools** to fix missing items:\n";
report += " - `mcp_generate_gemini_config`\n";
report += " - `track_project`\n";
report += " - `check_dependencies`\n";
return { content: [{ type: "text", text: report }] };
}