Automated summary
A guide to configuring a project so it works optimally with Claude Code: `.claude/` layout, settings files, permissions, and team sharing.
Strengths
- Ships a quick setup checklist plus three directory layouts (minimal, standard, full with hooks)
- Clear reference table showing which files to commit and which stay local (settings.local.json)
- Ready-to-fill CLAUDE.md template with an explanation of CLAUDE.md load precedence
- Concrete allow/deny permission examples in settings.json to constrain Bash commands
Limitations
- Heavily tied to the Claude Code ecosystem, so little carries over to other agents
- The provided document cuts off mid-way through the settings.json example, leaving it incomplete
- Hook scripts are only located by path; their content and format are not explained
Reach for it when bootstrapping a new repository or standardizing Claude Code configuration across an existing team.
Skip it if you want coding or application-design guidance rather than configuration of the tool itself.
Security analysis
SafeThe skill provides documentation and configuration guidance for setting up Claude Code projects. It does not instruct destructive or exfiltrating actions; examples of deny patterns for rm and sudo are included for safety. No commands are executed that could cause harm.
No concerns found
How this analysis is madeExamples
Set up this new TypeScript project for Claude Code: create the .claude directory, a CLAUDE.md with our stack and commands, and a settings.json with sensible permission allow/deny lists.I want to commit shared permissions for our team but keep my personal overrides private — configure .claude/settings.json and .claude/settings.local.json and gitignore the local one.Claude Code keeps asking for permission on every bun command in this project and seems to ignore our project instructions — check my .claude setup and CLAUDE.md placement and fix it.name: project-setup description: Guide for setting up projects to work optimally with Claude Code. Use when configuring new projects, migrating existing projects, setting up team permissions, or troubleshooting project configuration. Covers directory structure, settings files, permissions, and best practices. allowed-tools: ["Read", "Write", "Edit", "Bash", "Glob"]
Project Setup
Set up projects to work optimally with Claude Code with proper configuration, permissions, and team sharing.
Quick Reference
| Directory/File | Purpose | Committed |
|----------------|---------|-----------|
| .claude/ | Project configuration root | Yes (mostly) |
| .claude/settings.json | Project settings and hooks | Yes |
| .claude/settings.local.json | Personal project overrides | No |
| .claude/commands/ | Project slash commands | Yes |
| .claude/skills/ | Project-specific skills | Yes |
| CLAUDE.md | Project knowledge for Claude | Yes |
| .mcp.json | Shared MCP servers | Yes |
| ~/.claude/ | Personal global configuration | No |
Quick Setup Checklist
For new projects:
- [ ] Create
.claude/directory structure - [ ] Add
CLAUDE.mdwith project knowledge - [ ] Configure
.claude/settings.jsonwith permissions - [ ] Add
.claude/settings.local.jsonto.gitignore - [ ] Set up MCP servers in
.mcp.jsonif needed - [ ] Create project-specific slash commands
- [ ] Run
/initto verify setup
Directory Structure
Minimal Setup
project/
├── .claude/
│ └── settings.json # Basic permissions
└── CLAUDE.md # Project knowledge
Standard Setup
project/
├── .claude/
│ ├── settings.json # Shared project settings
│ ├── settings.local.json # Personal overrides (gitignored)
│ ├── commands/ # Project slash commands
│ │ └── deploy.md
│ └── skills/ # Project-specific skills
│ └── domain-model/
│ └── SKILL.md
├── .mcp.json # Shared MCP servers
├── CLAUDE.md # Project knowledge (root)
└── src/
└── CLAUDE.md # Subdirectory knowledge (optional)
Full Setup (with hooks)
project/
├── .claude/
│ ├── settings.json # Settings with hooks
│ ├── settings.local.json # Personal overrides
│ ├── commands/ # Slash commands
│ │ ├── deploy.md
│ │ └── test.md
│ ├── skills/ # Project skills
│ │ └── domain-model/
│ │ └── SKILL.md
│ └── hooks/ # Hook scripts
│ ├── format.sh
│ └── validate.py
├── .mcp.json # Shared MCP servers
└── CLAUDE.md # Project knowledge
CLAUDE.md
The most important file for Claude Code. Place in project root.
Template
# CLAUDE.md
## Project Overview
[Brief description of what this project does]
## Tech Stack
- [Framework/language]
- [Database]
- [Key dependencies]
## Commands
- `bun install` - Install dependencies
- `bun dev` - Start development server
- `bun test` - Run tests
- `bun build` - Build for production
## Architecture
[Key directories and their purposes]
## Code Style
- [Linting rules]
- [Naming conventions]
- [Patterns to follow]
## Important Notes
- [Gotchas and things Claude should know]
Location Precedence
Claude reads CLAUDE.md files in this order (all are included):
~/.claude/CLAUDE.md- Personal global instructions~/CLAUDE.md- Home directory instructions./CLAUDE.md- Project root./src/CLAUDE.md- Subdirectory (and any other CLAUDE.md files)
Tip: Use subdirectory CLAUDE.md files for module-specific guidance.
Settings Files
.claude/settings.json
Project settings committed to version control.
{
"permissions": {
"allow": [
"Bash(bun:*)",
"Bash(git:*)",
"Read",
"Write",
"Edit"
],
"deny": [
"Bash(rm -rf:*)",
"Bash(sudo:*)"
]
},
"env": {
"NODE_ENV": "development"
},
"hooks": {}
}
.claude/settings.local.json
Personal overrides (add to .gitignore).
{
"permissions": {
"allow": [
"Bash(docker:*)"
]
},
"env": {
"DEBUG": "true"
}
}
~/.claude/settings.json
User-level settings (applies to all projects).
{
"permissions": {
"allow": [
"Read",
"Glob",
"Grep"
],
"deny": []
},
"env": {}
}
Permission Setup
Permission Patterns
| Pattern | Matches |
|---------|---------|
| Read | All Read operations |
| Bash(git:*) | All git commands |
| Bash(npm install:*) | npm install with any args |
| Bash(bun test src/**:*) | bun test on src directory |
| Write(*.md) | Write to markdown files |
| Edit(src/**) | Edit files in src/ |
Recommended Permissions by Project Type
Node.js/Bun:
{
"permissions": {
"allow": [
"Bash(bun:*)", "Bash(npm:*)", "Bash(npx:*)",
"Bash(git:*)",
"Read", "Write", "Edit", "Glob", "Grep"
],
"deny": [
"Bash(rm -rf /*))",
"Bash(sudo:*)"
]
}
}
Python:
{
"permissions": {
"allow": [
"Bash(python:*)", "Bash(pip:*)", "Bash(uv:*)",
"Bash(pytest:*)",
"Bash(git:*)",
"Read", "Write", "Edit", "Glob", "Grep"
],
"deny": [
"Bash(rm -rf /*))",
"Bash(sudo:*)"
]
}
}
Rust:
{
"permissions": {
"allow": [
"Bash(cargo:*)", "Bash(rustc:*)",
"Bash(git:*)",
"Read", "Write", "Edit", "Glob", "Grep"
],
"deny": [
"Bash(rm -rf /*))",
"Bash(sudo:*)"
]
}
}
MCP Server Configuration
.mcp.json (Shared)
{
"mcpServers": {
"memory": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-memory"]
},
"github": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": {
"GITHUB_TOKEN": "${GITHUB_TOKEN}"
}
}
}
}
Adding Servers
# Add to project (creates .mcp.json)
claude mcp add --scope project memory -- npx -y @modelcontextprotocol/server-memory
# Add to user (all projects)
claude mcp add --scope user github -- npx -y @modelcontextprotocol/server-github
# Add remote server
claude mcp add --transport http context7 https://mcp.context7.com/v1/mcp
Hooks Setup
Add to .claude/settings.json:
{
"hooks": {
"PostToolUse": [
{
"matcher": "Write|Edit",
"hooks": [
{
"type": "command",
"command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/format.sh"
}
]
}
],
"SessionStart": [
{
"hooks": [
{
"type": "command",
"command": "echo \"Project: $(basename $CLAUDE_PROJECT_DIR)\""
}
]
}
]
}
}
Team Considerations
What to Commit
| File | Commit? | Reason |
|------|---------|--------|
| .claude/settings.json | Yes | Shared project config |
| .claude/settings.local.json | No | Personal overrides |
| .claude/commands/ | Yes | Team slash commands |
| .claude/skills/ | Yes | Team knowledge |
| .claude/hooks/ | Yes | Shared automation |
| .mcp.json | Yes | Shared MCP servers |
| CLAUDE.md | Yes | Project knowledge |
.gitignore Additions
# Claude Code personal settings
.claude/settings.local.json
.claude/*.local.json
# MCP server data (if any)
.mcp-data/
Team Onboarding
- Clone repository
- Run
/initto verify Claude Code setup - Create personal
.claude/settings.local.jsonfor overrides - Set required environment variables
- Run
/project-status(if command exists) to verify
Validation Commands
# Check Claude Code settings
claude config list
# Verify MCP servers
claude mcp list
# Check permissions
/permissions
# View hooks
/hooks
Common Issues
| Issue | Solution |
|-------|----------|
| Settings not loading | Check JSON syntax with jq . .claude/settings.json |
| MCP server not starting | Run claude mcp logs <name> |
| Permissions not applying | Check precedence: local > project > user |
| CLAUDE.md not read | Ensure it's in project root or cwd |
| Hooks not running | Verify script is executable |
Reference Files
| File | Contents | |------|----------| | CONFIGURATION.md | Deep dive into all configuration options | | PERMISSIONS.md | Permission patterns and security | | CHECKLIST.md | Complete setup and migration checklists |
From the file to a first result
The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.
View the source and supporting filesThis download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.
1. Download the file
Download SKILL.mdFrom the root of a test project, save the file as .skill-downloads/project-setup-for-claude-code-ms47vort/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.
Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.
mkdir -p '.skill-downloads/project-setup-for-claude-code-ms47vort' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/project-setup-for-claude-code-ms47vort/download' --output '.skill-downloads/project-setup-for-claude-code-ms47vort/SKILL.md.part' && mv '.skill-downloads/project-setup-for-claude-code-ms47vort/SKILL.md.part' '.skill-downloads/project-setup-for-claude-code-ms47vort/SKILL.md'2. Check prerequisites
Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.
Original excerpt: Quick Reference
| Directory/File | Purpose | Committed |
|---|---|---|
.claude/ | Project configuration root | Yes (mostly) |
.claude/settings.json | Project settings and hooks | Yes |
.claude/settings.local.json | Personal project overrides | No |
.claude/commands/ | Project slash commands | Yes |
.claude/skills/ | Project-specific skills | Yes |
CLAUDE.md | Project knowledge for Claude | Yes |
.mcp.json | Shared MCP servers | Yes |
~/.claude/ | Personal global configuration | No |
The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.
3. Load the skill
After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.
Claude Code
test -f '.skill-downloads/project-setup-for-claude-code-ms47vort/SKILL.md' && test -s '.skill-downloads/project-setup-for-claude-code-ms47vort/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/project-setup' && cp -R '.skill-downloads/project-setup-for-claude-code-ms47vort' '.claude/skills/project-setup'OpenSkills
OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.
Official OpenSkills installationopenskills install './.skill-downloads/project-setup-for-claude-code-ms47vort'openskills read 'project-setup-for-claude-code-ms47vort'Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.
For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.
openskills syncManual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.
4. Try a first task
Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:
Read .skill-downloads/project-setup-for-claude-code-ms47vort/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.
React Hook Form Best Practices
Development
Master React Hook Form: avoid anti-patterns, manage subscriptions, and handle reset, dirty state, and controlled inputs correctly.
Emotion to Mantine Migration
Development
Migrate Emotion styled-components to Mantine components with style props and CSS modules. Use when converting .styled.tsx files or removing @emotion imports.
Scope Creep Detector
Development
Analyzes git diffs against a stated intent to detect scope creep, unrelated files, broad PRs, and oversized changes, then suggests keep, split, or justify actions.