{
 "schema_version": 1,
 "generated": "2026-10-26",
 "id": "nduc99911-repo-context-mcp--repo-map-json-for-ci",
 "repo": "nduc99911/repo-context-mcp",
 "repo_url": "https://github.com/nduc99911/repo-context-mcp",
 "repo_slug": "nduc99911-repo-context-mcp",
 "title": "Generate repo maps as JSON for CI and scripts",
 "page_title": "How to generate repo maps as JSON for CI and scripts with Repo Context MCP",
 "summary": "Generate a repository map and a token-budgeted context pack as JSON so CI jobs and scripts can feed agents the right files.",
 "who": "A DevOps engineer building an AI review step in CI that should not paste the whole repo into a prompt.",
 "problem": "Dumping a full repo into an LLM blows the token budget and buries the relevant code.",
 "outcome": "map.json and pack.json your pipeline can pass to a model, focused on the folders that matter.",
 "steps": [
  "Run `git clone https://github.com/nduc99911/repo-context-mcp.git`, `cd repo-context-mcp`, `npm install` and `npm run build`",
  "Run `node dist/cli.js map . --json` from your project root and save the output as map.json",
  "Run `node dist/cli.js pack . --focus src --json` for a focused pack and save it as pack.json",
  "Cap size with `node dist/cli.js pack . --focus auth,api --max-tokens 8000`",
  "Feed the JSON to your review script in CI"
 ],
 "agent_prompt": "In CI, run repo-context-mcp's `map . --json` and `pack . --focus <dirs> --max-tokens <n>`, then review only the packed files for <goal>. Report the token count and list any changed file the pack left out.",
 "agents": [
  "any"
 ],
 "difficulty": "Intermediate",
 "time": "15 minutes",
 "basis": "readme",
 "caveat": "The npx package is marked as after publish in the README, so build from source in CI until it is on npm.",
 "category": "Software and DevOps",
 "tags": [
  "Software and DevOps"
 ],
 "lang": "typescript",
 "requirements": [
  "Node.js 18+"
 ],
 "risk": "none",
 "seen_in_the_wild": false,
 "mentioned_publicly": false,
 "risks": [],
 "best": false,
 "score": 0.8,
 "evidence": [],
 "url": "https://dedupedai.com/use-cases/nduc99911-repo-context-mcp/repo-map-json-for-ci/",
 "md": "https://dedupedai.com/use-cases/nduc99911-repo-context-mcp/repo-map-json-for-ci/index.md",
 "disclaimer": "Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked \"Seen in the wild\", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email hello@dedupedai.com and we will look at it promptly.",
 "api": "https://dedupedai.com/api/v1/usecases/nduc99911-repo-context-mcp--repo-map-json-for-ci.json",
 "api_version": "v1"
}
