agent-browser-automati…
Automate browser interactions for development testing using Puppeteer MCP
Generate project-specific .claude/settings.json based on project context with appropriate hooks and configurations
How it fires
How this command gets triggered: by you, by Claude, or both.
/generate-project-claude-settingsContext preview
What this command does when you run it.
Generate project-specific .claude/settings.json based on project context with appropriate hooks and configurations
allowed-tools: Bash(fd:*), Bash(rg:*), Bash(jq:*), Bash(gdate:*), Bash(which:*), Read, Write, MultiEdit, WebFetch name: "Generate Project Claude Settings" description: "Generate project-specific .claude/settings.json based on project context with appropriate hooks and configurations" author: "wcygan" tags: ["scaffold"] version: "1.0.0" created_at: "2025-07-14T00:00:00Z" updated_at: "2025-07-14T00:00:00Z"
Generate a project-specific .claude/settings.json file based on the project context, including appropriate permissions, hooks, and configurations.
STEP 1: Analyze project context and determine configuration needs
# Create session state
session_id="$SESSION_ID"
state_file="/tmp/claude-settings-gen-$session_id.json"
# Initialize project analysis
echo '{
"session_id": "'$session_id'",
"project_root": "'$(pwd)'",
"timestamp": "'$(gdate -Iseconds 2>/dev/null || date -Iseconds)'",
"detected_languages": [],
"detected_tools": [],
"suggested_hooks": [],
"existing_settings": null
}' > "$state_file"**Project Type Detection:**
**Tool Detection:**
# Check for common development tools tools_found="" [ -f "package.json" ] && tools_found="$tools_found npm" [ -f "deno.json" ] && tools_found="$tools_found deno" [ -f "Cargo.toml" ] && tools_found="$tools_found cargo" [ -f "go.mod" ] && tools_found="$tools_found go" [ -f "pom.xml" -o -f "build.gradle" ] && tools_found="$tools_found java" [ -f "requirements.txt" -o -f "Pipfile" ] && tools_found="$tools_found python"
STEP 2: Fetch latest Claude Code settings documentation
STEP 3: Interactive configuration gathering
PROMPT user for configuration preferences:
1. **Permission Mode**:
2. **Hook Preferences**:
3. **MCP Server Setup**:
STEP 4: Generate base configuration structure
CREATE initial settings object based on project analysis:
{
"$schema": "https://json.schemastore.org/claude-code-settings.json",
"permissions": {
"allow": [],
"deny": [],
"defaultMode": "ask"
},
"hooks": {},
"env": {},
"includeCoAuthoredBy": true
}STEP 5: Add language-specific configurations
FOR EACH detected language, add appropriate settings:
**JavaScript/TypeScript Projects:**
{
"permissions": {
"allow": [
"Bash(npm run:*)",
"Bash(npx:*)",
"Bash(deno task:*)",
"Read(**/*.js)",
"Read(**/*.ts)",
"Write(**/*.js)",
"Write(**/*.ts)"
]
},
"hooks": {
"PostToolUse": [
{
"matcher": "Write|Edit|MultiEdit",
"hooks": [
{
"type": "command",
"command": "npx prettier --write $FILE_PATH 2>/dev/null || true"
}
]
}
]
}
}**Go Projects:**
{
"permissions": {
"allow": [
"Bash(go test:*)",
"Bash(go run:*)",
"Bash(go build:*)",
"Bash(go fmt:*)"
]
},
"hooks": {
"PostToolUse": [
{
"matcher": "Write|Edit|MultiEdit",
"hooks": [
{
"type": "command",
"command": "[ \"${FILE_PATH##*.}\" = \"go\" ] && go fmt $FILE_PATH || true"
}
]
}
]
}
}**Rust Projects:**
{
"permissions": {
"allow": [
"Bash(cargo build:*)",
"Bash(cargo test:*)",
"Bash(cargo run:*)",
"Bash(cargo fmt:*)"
]
},
"hooks": {
"PostToolUse": [
{
"matcher": "Write|Edit|MultiEdit",
"hooks": [
{
"type": "command",
"command": "[ \"${FILE_PATH##*.}\" = \"rs\" ] && rustfmt $FILE_PATH || true"
}
]
}
]
}
}STEP 6: Add common hooks based on user preferences
**Git Auto-Stage Hook:**
{
"PostToolUse": [
{
"matcher": "Write|Edit|MultiEdit",
"hooks": [
{
"type": "command",
"command": "[ -d .git ] && git add $FILE_PATH 2>/dev/null || true"
}
]
}
]
}**Command Logging Hook:**
{
"PreToolUse": [
{
"matcher": "Bash",
"hooks": [
{
"type": "command",
"command": "echo \"$(date): $TOOL_INPUT\" >> ~/.claude/command-log.txt"
}
]
}
]
}**Notification Hook:**
{
"Stop": [
{
"matcher": "",A lightweight (~46kB) and comprehensive CLI tool for managing Claude commands, configurations, and workflows.
Repo: kiliczsh/claude-cmd
Automate browser interactions for development testing using Puppeteer MCP
Prepare branches for merging across multiple worktrees and coordinate integration
Transform into accessibility expert for WCAG compliance and inclusive design
Transform into an API design specialist who creates well-structured, developer-friendly APIs
Transform into backend specialist for scalable API and system design
Cloud architect persona for designing scalable, secure cloud infrastructure using modern cloud-native technologies