Drop one file. Tell your AI to read it. Done.
A single 7,000-line markdown bootstrap that turns Claude Code, ChatGPT Codex CLI, Cursor, and GitHub Copilot into a disciplined teammate — 13-section rules, 5 safety hooks, session-resume, dual-write memory, and bilingual GitHub files. Zero install. One source of truth.
# Fetch the bootstrap file
curl -fsSL https://raw.githubusercontent.com/kernalix7/ai-project-setup/main/AI_PROJECT_SETUP.md > AI_PROJECT_SETUP.md
# Open your AI tool, then say:
# "Read AI_PROJECT_SETUP.md and execute it."
# "AI_PROJECT_SETUP.md 읽고 실행해줘"
# 1–3 minutes later, verify:
./tmp-igbkp/verify-setup.sh # → Pass: 83 Fail: 0 Warn: 0
Works with
English · 한국어 · Setup file · Contributing · Security · Changelog
📌 Status: v5.2 stable
ai-project-setup ships a single-file bootstrap (
AI_PROJECT_SETUP.md, ~7,600 lines) that any AI coding assistant reads and executes to produce a complete, multi-tool, gitignored AI tooling layout. v5.2 is the first polished GitHub repository release: expanded README, bilingual standard docs, issue/PR templates, and stricter no-footprint.gitignore. v5.1 moved the self-update source from a gist to this repository, so projects on v5.0 or earlier fetch v5.1 once from the legacy gist (frozen as a migration bridge), then all subsequent updates come from here. The artifact is idempotent and self-healing — re-running setup on an existing project repairs drift, force-overwrites stale shipped scripts with.bakbackups, and preserves user content (CLAUDE.mdsections 1–7 and 11, memory files, project agents).
One file, every AI tool. Drop AI_PROJECT_SETUP.md at your project root, tell the AI to read it, and in 1–3 minutes you have rules, hooks, session-resume, slash commands, default agents, a backup toolkit, and bilingual GitHub standard files — all gitignored so your project git history stays clean. Absolute Rule #19: AI tooling leaves zero footprint in your project's git history.
📑 Table of contents
- Why this exists
- Quick start
- What gets created
- Lifecycle
- Key features
- Supported AI tools
- Comparison
- Documentation
- Self-update
- Forking
- FAQ
- Roadmap
- Star history
- Support
- License
🎯 Why this exists
Every new project, you re-do the same AI setup. This file does it once, deterministically, across multiple AI tools:
| What you used to do every time | What this file does automatically |
|---|---|
Write CLAUDE.md / AGENTS.md / .cursorrules by hand |
✅ 13 sections generated + 3-tool symlink sync |
Block dangerous commands (rm -rf /, force push, secret leaks) |
✅ Kernel-level PreToolUse hook |
Set up session resume for /clear · crash · rate-limit |
✅ 3-tier auto-save (current/handoff/recovery) |
| Configure memory · slash commands · default agents | ✅ 10+ commands + 4 agents installed |
| Create README / SECURITY / CONTRIBUTING / CHANGELOG | ✅ Bilingual EN/KO generation |
| Stop AI tool files from leaking into git history | ✅ 22 .gitignore entries auto-applied |
⚡ Quick start
One-liner (any git repository):
curl -fsSL https://raw.githubusercontent.com/kernalix7/ai-project-setup/main/AI_PROJECT_SETUP.md \
> AI_PROJECT_SETUP.mdThen open your AI tool and tell it to execute the file:
claude # or: codex, cursor ., or VS Code with CopilotTell the AI (English or Korean both work):
Read
AI_PROJECT_SETUP.mdand execute it.
AI_PROJECT_SETUP.md 읽고 실행해줘
Wait 1–3 minutes, then verify:
./tmp-igbkp/verify-setup.sh
# → Pass: 83 Fail: 0 Warn: 0 — All required checks passedThat's it. Everything created is gitignored — your project's git history stays clean.
📦 What gets created
your-project/
|-- CLAUDE.md -> symlink to .priv-storage/CLAUDE.md
|-- AGENTS.md -> symlink to .priv-storage/CLAUDE.md # Codex / Copilot
|-- .cursorrules -> symlink to .priv-storage/CLAUDE.md # Cursor
|-- WORK_STATUS.md -> current work state (project content)
|
|-- .priv-storage/ [gitignored] all AI tooling lives here
| |-- CLAUDE.md # 13-section project rules (~10kB cap)
| |-- CLAUDE.local.md # per-developer overrides
| |-- POST_SETUP_INDEX.md # 50-line pointer (saves ~25k tokens/session)
| |-- AI_PROJECT_SETUP.md # archived, never re-read
| |-- memory/ # dual-written to ~/.claude/projects/ (cross-machine sync)
| |-- sessions/ # current.md, handoff-{date}.md, recovery.md, read-log.tsv
| `-- .claude/
| |-- settings.json # statusLine + 5 hooks + outputStyle
| |-- hooks/ # PreToolUse / PostToolUse / SessionStart / PreCompact / Stop
| |-- agents/ # tech-lead, explorer, code-reviewer, log-analyzer
| |-- commands/ # 10+ slash commands
| |-- skills/ and rules/ # on-demand knowledge
| |-- output-styles/terse.md
| `-- statusline # context percent / rate-limit ETA
|
|-- tmp-igbkp/ [gitignored] backup and verification toolkit (9 scripts)
| |-- verify-setup.sh # one-command health check (83+ assertions)
| |-- smoke-test-hooks.sh # mock-payload hook validation
| |-- secret-guard.sh # 14-pattern pre-commit scanner
| |-- archive.sh / restore.sh # AES-256-CBC + PBKDF2 600k iterations
| |-- purge-history.sh # git-filter-repo wrapper
| |-- setup-worktree.sh # bridges worktrees to main .priv-storage/
| |-- codex-relay-{check,run}.sh # Claude <-> Codex parallel lanes
| `-- uninstall.sh # safe rollback with backup
|
|-- .mcp.json [gitignored] MCP server registry (env-var refs only)
|
|-- README.md, SECURITY.md, CONTRIBUTING.md, CODE_OF_CONDUCT.md, CHANGELOG.md
|-- docs/{README,SECURITY,CONTRIBUTING,CODE_OF_CONDUCT,CHANGELOG}.ko.md
`-- .github/{ISSUE_TEMPLATE/,PULL_REQUEST_TEMPLATE.md}
Only
WORK_STATUS.md, GitHub standard files, thedocs/Korean mirrors, and.github/get committed. Everything inside.priv-storage/andtmp-igbkp/is gitignored by design.
🔄 Lifecycle
[1. INITIAL SETUP]
Prompt: "Read AI_PROJECT_SETUP.md and execute it."
- Auto-detects Scenario A/B/C
- Creates everything above, then runs STEP 6
- Archives AI_PROJECT_SETUP.md into .priv-storage/
- Prints "Setup Complete" only if automode-validate.sh passes
|
v
[2. NORMAL SESSIONS]
- SessionStart hook injects last handoff + current.md tail
- AI reads CLAUDE.md (~200 lines) + POST_SETUP_INDEX.md (~50)
- Does not re-read the 7000-line setup file, saving ~25k tokens/session
- PreToolUse blocks dangerous commands + oversized Reads
- PostToolUse appends to current.md + dual-writes memory
- Stop hook writes handoff-{date}.md
- PreCompact hook writes recovery.md (best-effort)
|
v
[3. CRASH / RATE-LIMIT / /clear]
- Next session: SessionStart auto-loads handoff + recovery
- AI resumes without "where were we?" questions
|
v
[4. SELF-UPDATE]
Trigger: "update setup" or Korean "AI_PROJECT_SETUP 업데이트해"
- Fetches latest from GitHub raw URL
- Replaces archived setup file
- Force-overwrites all 30+ shipped scripts with .bak backup
- Re-runs automode-validate gate
- Reports: "Updated: vOLD -> vNEW. Recommend /clear."
Three setup scenarios
| Scenario | When | What the AI does |
|---|---|---|
| A — existing | .priv-storage/ exists or real CLAUDE.md at root |
Update/repair in place. Force-overwrite shipped scripts (with .bak), preserve user content. |
| B — empty/new | No .priv-storage/, no CLAUDE.md at root |
Full setup from scratch — STEP 0 detection → STEPs 1–12 → archive. |
| C — broken | Files at root that look like CLAUDE.md but aren't, or partial leftover state | Detect, classify, convert to canonical layout, then bridge into A's STEPs 4–12. |
✨ Key features
|
🛡️ Safety hooks (Claude Code)
|
🔄 Resilience
|
|
🤖 Default agents (token-efficient)
|
⚡ Slash commands
|
|
💰 Token discipline (Absolute Rule #20)
|
🔐 Secret guard
|
|
🌏 Multi-tool parity
|
🔀 Cross-AI Codex relay (v4.9+, Claude Code only)
|
🤝 Supported AI tools
| Tool | Min version | Reads | Hook support |
|---|---|---|---|
| Claude Code | 2.0+ | CLAUDE.md |
✅ Full (5 hook events) |
| ChatGPT Codex CLI | 0.10+ | AGENTS.md → CLAUDE.md |
❌ Policy-only |
| Cursor | 0.40+ | .cursorrules → CLAUDE.md |
❌ Policy-only |
| GitHub Copilot | 1.150+ | AGENTS.md |
❌ Policy-only |
| claude.ai (web) | current | upload CLAUDE.md |
❌ Policy-only |
| Any MCP-aware tool | — | depends | ❌ Policy-only |
Policy-only = rules enforced via prompt content. No kernel-level block, but the AI follows them because they're in the rules file it reads.
⚖️ Comparison
| This file | .cursorrules only |
Custom CLAUDE.md | Per-tool CLI tool | |
|---|---|---|---|---|
| Single source of truth across tools | ✅ | ❌ Cursor only | ❌ Claude only | ❌ |
| Zero install | ✅ | ✅ | ✅ | ❌ |
| Safety hooks (kernel-level) | ✅ | ❌ | manual | maybe |
| Session resume on crash | ✅ | ❌ | manual | maybe |
| Token discipline enforcement | ✅ | ❌ | manual | ❌ |
| Self-update from upstream | ✅ | ❌ | ❌ | ✅ |
| Bilingual GitHub files | ✅ | ❌ | ❌ | ❌ |
| AI-tooling leak prevention | ✅ | ❌ | manual | ❌ |
| Cross-AI relay (Claude ↔ Codex) | ✅ | ❌ | ❌ | ❌ |
| Works on Linux / macOS / Windows | ✅ | ✅ | ✅ | depends |
📚 Documentation
| Document | What's inside |
|---|---|
| AI_PROJECT_SETUP.md | The artifact — 7,600-line bootstrap that creates everything |
| docs/README.ko.md | This README in Korean |
| CONTRIBUTING.md · 한국어 | Development setup, version-bump checklist, PR conventions |
| SECURITY.md · 한국어 | Security disclosure process, secret-guard patterns |
| CODE_OF_CONDUCT.md · 한국어 | Contributor Covenant v2.1 |
| CHANGELOG.md · 한국어 | Full version history |
🔁 Self-update
Trigger via natural language: "AI_PROJECT_SETUP 업데이트해" / "update AI_PROJECT_SETUP" / "fetch latest setup".
The AI:
- Fetches
https://raw.githubusercontent.com/kernalix7/ai-project-setup/main/AI_PROJECT_SETUP.md - Compares
Last Updatedline and version against local copy - If newer: replaces
.priv-storage/AI_PROJECT_SETUP.md, force-overwrites all 30+ shipped scripts with.bakbackup - Merges template sections of
CLAUDE.md(§8/9/10/12/13) while preserving project content (§1–7, §11) - Re-runs the validator gate
- Reports
Updated: vOLD → vNEW. Force-patched N shipped scripts. Recommend /clear.
Single command, no re-run prompt (since v4.6+).
v5.0 → v5.1 migration: v5.1 moved the update source from a gist to this repository. Projects on v5.0 or earlier fetch v5.1 once from the legacy gist (frozen at v5.1 as a migration bridge), then all subsequent updates come from this repository.
🍴 Forking
To point forks at your own repo for self-update:
- Edit
AI_PROJECT_SETUP.md— replace both occurrences ofkernalix7/ai-project-setupwith{your-user}/{your-repo}:- The repo URL in the Source of Truth block
- The raw URL in the same block and in the self-update protocol Step 2
- Optionally remove the legacy gist URL block (only needed when migrating users from pre-v5.1).
- Commit and push to your fork's
mainbranch.
For downstream project customization, edit the generated .priv-storage/CLAUDE.md directly — sections 1–7 and 11 are preserved across self-updates.
❓ FAQ
Why a single 7,000-line markdown file instead of a CLI tool?
AI coding assistants natively read markdown. A CLI tool needs installation, version management, and platform support. A markdown file works everywhere any AI works — Linux, macOS, Windows, containers, browser-based agents — with zero install.
Doesn't 7,000 lines blow up my context window?
Only on initial setup (~25k tokens, one time). After setup, the file is archived and a 50-line POST_SETUP_INDEX.md becomes the entry point. Normal sessions consume ~200 lines of CLAUDE.md + the index — about 4k tokens.
Is it safe that nothing gets committed? My CI/CD doesn't see hooks/agents.
Correct, and intentional. AI tooling is per-developer ergonomics; CI/CD runs against your code, not your AI config. Teammates who don't use AI see no change. Those who do run setup themselves and get the same config from this same source.
Will this work with [some new AI tool that doesn't exist yet]?
If the tool reads markdown rules files (CLAUDE.md / AGENTS.md / .cursorrules / similar), yes — point it at any of the three symlinks. If it supports MCP, it'll find .mcp.json automatically. Hooks are Claude Code-specific.
How do I uninstall?
./tmp-igbkp/uninstall.sh
Backs up everything to tmp-igbkp/uninstall-backup-{ts}/ before removing. Add --clean-gitignore to also remove the AI-tooling block from .gitignore.
What about Windows?
Works on Git Bash, WSL, and MSYS2. Native PowerShell is not supported for hooks (they're bash scripts), but the rules file itself is plain markdown and works with any AI tool on Windows.
Can I use this with multiple AI tools simultaneously in the same project?
Yes — that's the design. Claude Code reads CLAUDE.md, Codex/Copilot read AGENTS.md, Cursor reads .cursorrules. All three are symlinks to the same .priv-storage/CLAUDE.md so updates are atomic.
I found a bug / want a feature.
Open an issue or PR at https://github.com/kernalix7/ai-project-setup. See CONTRIBUTING.md.
🗺️ Roadmap
- v5.3 —
.devcontainer/template, GitHub Actions workflow for setup verification - v5.4 — Native Windows PowerShell hooks (experimental)
- v6.0 — Pluggable rule modules (
.priv-storage/.claude/rules/<lang>/)
See CHANGELOG.md for version history.
⭐ Star history
💛 Support
If ai-project-setup saved you setup time:
Ko-fi handles international cards and PayPal; fairy.hada.io is a Korean tipping platform. Bug reports, PRs, and ⭐ stars on the repo are equally appreciated and free.
📄 License
MIT — Kim DaeHyun (kernalix7@kodenet.io)





















