Intelligent, proactive permission management for Claude Code that eliminates configuration friction.
Tired of manually configuring Claude Code permissions? This skill transforms permission management from tedious JSON editing into simple, natural language conversations. Just say what you want to enable, and the skill handles the rest - automatically, safely, and intelligently.
Before:
- Manually edit ~/.claude/settings.json
- Look up permission syntax
- Remember which commands are safe
- Forget to deny sensitive files
- Get stuck on unknown tools
After:
- "enable git" - Auto-adds safe git commands
- "make markdown files editable" - Instant configuration
- "this is a Rust project" - Complete setup in seconds
- "enable terraform" - Automatic research and configuration
- Safety rules applied automatically
The easiest way to install this skill is via the Skilz Universal Installer:
# Install skilz CLI (if not already installed)
npm install -g skilz
# Install this skill
skilz install SpillwaveSolutions_claude_permissions_skill/claude-permissionsOr use npx without global installation:
npx skilz install SpillwaveSolutions_claude_permissions_skill/claude-permissionsView this skill on the marketplace: skillzwave.ai/skill/SpillwaveSolutions__claude_permissions_skill__claude-permissions__SKILL/
Clone this repository directly into your Claude Code skills directory:
cd ~/.claude/skills
git clone https://github.com/SpillwaveSolutions/claude_permissions_skill.git claude-permissionsAfter installation, the skill is immediately available to Claude Code. No restart required.
Start Claude Code and try:
User: "enable git read commands"
Claude will automatically:
- Add read-only git permissions (status, log, diff, show, branch)
- Apply safety deny rules (no
--forceoperations) - Create a backup of your settings
- Validate the configuration
- Confirm what was added
# Make all markdown files editable
"make all markdown files editable"
# Set up a TypeScript project
"this is a TypeScript project, make it editable"
# Enable write operations for git
"enable git commits and pushes"
# Enable GCP read commands
"enable gcloud list and describe commands"
# Apply a pre-built profile
"apply development profile"Stop editing JSON. Just describe what you want:
| What You Say | What Happens |
|---|---|
| "enable git" | Adds read-only git commands |
| "enable git pushes" | Adds write git operations + safety rules |
| "make Rust files editable" | Adds .rs file patterns + cargo commands |
| "this is a TypeScript project" | Complete TypeScript + npm setup |
| "enable kubectl read commands" | Adds kubernetes read-only operations |
Pre-configured with read vs write operations for:
Version Control & Collaboration:
git- Distributed version control
Cloud Platforms:
gcloud(Google Cloud)aws(Amazon Web Services)az(Microsoft Azure)
Containers & Orchestration:
docker- Container platformkubectl- Kubernetes controlhelm- Kubernetes package manager
Build Tools & Package Managers:
npm,yarn(JavaScript/Node.js)pip(Python)maven,gradle(Java)cargo(Rust)go(Go)bundle(Ruby)composer(PHP)
Infrastructure as Code:
terraform- Multi-cloud IaCpulumi- Modern IaCansible- IT automation
AI CLIs:
claude- Claude Code CLIgemini- Gemini CLI
Each tool has carefully curated lists of:
- Read-only operations (safe, recommended)
- Write operations (with appropriate safeguards)
- Dangerous operations (auto-denied)
Automatically detects project type and applies appropriate templates:
Cargo.toml -> Rust project
pom.xml -> Java Maven
build.gradle -> Java Gradle
package.json + tsconfig -> TypeScript
package.json (only) -> JavaScript
pyproject.toml -> Python
go.mod -> Go
Gemfile -> Ruby
composer.json -> PHP
*.csproj -> C#
CMakeLists.txt -> C++
Package.swift -> Swift
Each template includes:
- File editing patterns (
.rs,.java,.ts, etc.) - Build tool commands (safe operations only)
- Deny rules for build artifacts and sensitive files
Encountered a tool not in the database? No problem!
Automatic research workflow:
- Check built-in database (
cli_commands.json) - Research using (in priority order):
- Perplexity MCP (if available)
- Brave Search MCP
- Gemini skill (if available)
- Built-in WebSearch
- Parse results for read vs write operations
- Present findings to user for confirmation
- Apply permissions
- Optionally cache for future use
Example with Terraform (unknown tool):
User: "enable terraform read commands"
Claude:
Checking database... not found
Researching via Perplexity...
Found these read-only commands:
- terraform plan (preview changes)
- terraform show (display state)
- terraform validate (check syntax)
- terraform state list (list resources)
- terraform output (show outputs)
Write commands (will be denied):
- terraform apply (create resources)
- terraform destroy (delete resources)
Should I add the read-only commands? (y/n)
User: y
Claude:
Added 5 terraform read commands
Denied terraform apply, destroy
Backup created: ~/.claude/settings.20250116_143022.backup
Every permission change includes automatic deny rules for:
Sensitive Files:
.env, .env.* - Environment variables
*.key, *.pem - Private keys & certificates
.aws/**, .ssh/** - Cloud & SSH credentials
secrets/** - Secrets directories
credentials/** - Credential files
Dangerous Commands:
rm *, rm -rf - File deletion
sudo * - Privilege escalation
chmod, chown - Permission changes
dd, mkfs - Disk operations
curl * | bash - Pipe to shell execution
Force Operations:
git push --force - Force push
git reset --hard - Hard reset
docker rm -f - Force container removal
terraform destroy - Infrastructure destruction
Production Deployments:
npm publish - NPM registry
mvn deploy - Maven repository
cargo publish - Crates.io
docker push *prod* - Production images
Three security levels available:
minimal(5 rules) - Basic protectionstandard(13 rules) - Recommended defaultstrict(25 rules) - Maximum security
Before every change:
- Creates timestamped backup (
settings.YYYYMMDD_HHMMSS.backup) - Validates permission syntax
- Checks for conflicts (allow vs deny)
- Warns about security issues
- Applies changes safely
- Reports what was changed
Easy rollback:
# List available backups
ls -la ~/.claude/settings.*.backup
# Restore from backup
cp ~/.claude/settings.20250116_143022.backup ~/.claude/settings.jsonPre-built profiles for common workflows:
Use case: Active feature development
{
"allows": [
"Full editing of src/, test/, docs/",
"Git read + write (no --force)",
"Build tool commands (test, compile, build)",
"Package manager (install, test)"
],
"denies": [
"Sensitive files (.env, .key, .pem)",
"Dangerous commands (rm, sudo)",
"Production deployments (publish, deploy)",
"Build artifacts (target/, node_modules/)"
]
}Use case: Continuous integration pipelines
{
"allows": [
"Read access only",
"Git read commands",
"Build and test commands",
"Docker build and tag"
],
"denies": [
"All writes",
"Git push",
"Docker push",
"Deployment commands"
]
}Use case: Code review, security audit
{
"allows": [
"Read access only"
],
"denies": [
"All writes and edits",
"All bash commands",
"Web access"
]
}All 7 profiles:
read-only- Code review, auditdevelopment- Active development (recommended)ci-cd- Automated testingproduction- Monitoring onlydocumentation- Docs writingcode-review- PR reviewtesting- TDD workflow
Apply a profile:
User: "apply development profile"
User: "use read-only profile"
User: "set up CI/CD permissions"
All functionality is also available as standalone Python scripts:
# Navigate to skill directory
cd ~/.claude/skills/claude-permissions
# Apply specific permissions
python3 scripts/apply_permissions.py \
--add "Bash(git status)" \
--add "Bash(git log)" \
--add "Write(**.md)"
# Apply a profile
python3 scripts/apply_permissions.py --profile development
# Use global settings instead of project
python3 scripts/apply_permissions.py --global --add "Read"
# Add deny rules
python3 scripts/apply_permissions.py \
--deny "Bash(rm *)" \
--deny "Read(.env*)"
# Detect current project type
python3 scripts/detect_project.py
python3 scripts/detect_project.py --permissions # Show recommended perms
# Validate configuration
python3 scripts/validate_config.py ~/.claude/settings.json
python3 scripts/validate_config.py ~/.claude/settings.json -v # Verbose
# Get help
python3 scripts/apply_permissions.py --helpClaude Code uses a hierarchical config system (highest priority first):
1. Command-line arguments (--allowedTools flag)
2. Enterprise policies (if applicable)
3. .claude/settings.local.json (git-ignored, personal)
4. .claude/settings.json (version controlled, team)
5. ~/.claude/settings.json (user global)
6. ~/.claude.json (legacy global)
Default behavior:
- Applies to project settings if in a project directory
- Otherwise applies to user global settings
Specify location explicitly:
User: "enable git and add to global settings"
User: "make markdown editable in project settings only"
Support for directory-specific permissions:
User: "make files in src/ editable"
-> Adds: Write(src/**), Edit(src/**)
User: "allow editing docs folder"
-> Adds: Write(docs/**), Edit(docs/**)
User: "enable TypeScript in src only"
-> Adds: Write(src/**.ts), Write(src/**.tsx)
claude-permissions/
├── SKILL.md # Main skill instructions
├── README.md # This file
├── LICENSE # MIT License
├── .gitignore # Git ignore patterns
│
├── scripts/ # Python automation scripts
│ ├── apply_permissions.py # Core permission manager
│ ├── detect_project.py # Project type detection
│ └── validate_config.py # Configuration validator
│
├── references/ # Knowledge databases
│ ├── cli_commands.json # 17 CLI tools database
│ ├── project_templates.json # 12 language templates
│ └── security_patterns.json # Universal safety rules
│
├── guides/ # Workflow guides
│ └── workflows/ # Step-by-step workflows
│ ├── cli-tool-workflow.md
│ ├── file-pattern-workflow.md
│ ├── project-setup-workflow.md
│ ├── profile-application-workflow.md
│ ├── validation-workflow.md
│ ├── backup-restore-workflow.md
│ └── research-workflow.md
│
└── assets/ # Pre-built configurations
└── permission_profiles.json # 7 permission profiles
graph TD
A[User Request] --> B{Parse Intent}
B -->|CLI Tool| C[Check Database]
B -->|File Pattern| D[Convert to Glob]
B -->|Project Type| E[Detect Project]
B -->|Profile| F[Load Profile]
C -->|Found| G[Extract Commands]
C -->|Not Found| H[Research Online]
H --> I[Perplexity MCP]
I -->|Not Available| J[Brave Search]
J -->|Not Available| K[Gemini Skill]
K -->|Not Available| L[WebSearch]
I --> M[Parse Results]
J --> M
K --> M
L --> M
M --> N[User Confirmation]
N --> G
D --> O[Build Permissions]
E --> P[Load Template]
F --> O
G --> O
P --> O
O --> Q[Apply Safety Rules]
Q --> R[Validate Syntax]
R --> S[Check Conflicts]
S --> T[Create Backup]
T --> U[Apply Changes]
U --> V[Report Success]
- User Input - Natural language request
- Intent Detection - Parse what user wants
- Knowledge Lookup - Check built-in database OR research online
- Permission Building - Construct allow/deny rules
- Safety Application - Add security deny rules
- Validation - Check syntax and conflicts
- Backup - Create timestamped backup
- Application - Write to settings file
- Confirmation - Report changes to user
Edit references/cli_commands.json:
{
"your-tool": {
"description": "Your tool description",
"read_only": [
"list",
"show",
"describe",
"get"
],
"write": [
"create",
"update",
"delete"
],
"dangerous": [
"delete",
"destroy",
"force-*"
],
"notes": "Additional context or patterns"
}
}Edit references/project_templates.json:
{
"your-language": {
"description": "Your language description",
"file_patterns": {
"allow": [
"Write(src/**.ext)",
"Edit(**.ext)",
"Write(**.config)"
],
"deny": [
"Write(build/**)",
"Write(dist/**)"
]
},
"commands": {
"allow": [
"Bash(tool build)",
"Bash(tool test)",
"Bash(tool check)"
],
"deny": [
"Bash(tool publish)",
"Bash(tool deploy)"
]
}
}
}Edit assets/permission_profiles.json:
{
"your-profile": {
"description": "Profile description",
"allowedTools": [
"Read",
"Write(specific/**)",
"Bash(safe-command *)"
],
"deny": [
"Bash(dangerous-command *)",
"Write(sensitive/**)"
],
"use_cases": [
"Use case 1",
"Use case 2"
]
}
}Edit references/security_patterns.json:
{
"your_category": {
"description": "Category description",
"patterns": [
"Read(sensitive-pattern*)",
"Bash(dangerous-command *)",
"Write(protected/**)"
]
}
}Symptoms: Added permissions but Claude still asks for approval
Solutions:
- Restart Claude Code (required for settings to reload)
- Verify settings were updated:
cat ~/.claude/settings.json | grep -A 20 permissions
- Check for typos in permission rules
- Ensure correct settings file was modified
Known Issue: Claude Code may ignore deny rules in some cases
Workarounds:
- Use multiple layers of deny rules
- Apply deny rules at project-local level (
.claude/settings.local.json) - Use enterprise policies if available
- Contact Claude support about this limitation
Symptoms: Skill doesn't automatically research unknown tools
Check:
- Verify MCP servers are configured:
claude mcp
- Check available tools in order:
mcp__perplexity-ask__perplexity_askmcp__brave-search__brave_web_searchgeminiskill (check~/.claude/skills/gemini)WebSearch(built-in, always available)
Manual fallback:
- Research the tool manually
- Add to
references/cli_commands.json - Or specify commands directly:
python3 scripts/apply_permissions.py \ --add "Bash(tool read-command)" \ --deny "Bash(tool write-command)"
Symptoms: Skill reports validation errors
Debug:
# Run validator with verbose output
python3 scripts/validate_config.py ~/.claude/settings.json -v
# Common errors:
# - Invalid tool name: Check against VALID_TOOLS list
# - Missing parenthesis: Ensure Tool(pattern) format
# - Conflicts: Review allow vs deny rulesFix:
- Review error messages carefully
- Fix syntax in settings file
- Re-validate
- Or restore from backup:
cp ~/.claude/settings.20250116_143022.backup ~/.claude/settings.json
Symptoms: "No project type detected"
Causes:
- Empty directory
- Unsupported project type
- Missing indicator files
Solutions:
- Add indicator file (e.g.,
package.json,Cargo.toml) - Manually specify project type:
User: "treat this as a TypeScript project" - Add custom template to
project_templates.json
Symptoms: Claude asks for approval too often
Solutions:
- Use broader patterns:
Bash(git *) # Instead of individual git commands Write(src/**) # Instead of specific file types - Apply a comprehensive profile:
User: "apply development profile" - Review and consolidate permission rules
We welcome contributions! Here's how you can help:
Found a bug or have a suggestion? Open an issue
Please include:
- Claude Code version
- Operating system
- Steps to reproduce
- Expected vs actual behavior
- Error messages or logs
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Test thoroughly
- Commit with clear messages
- Push to your fork
- Open a Pull Request
Know the read vs write commands for a tool? Add it to cli_commands.json:
- Research the tool's commands
- Categorize: read-only, write, dangerous
- Add to database with description
- Test the configuration
- Submit PR
Support a new language? Add a template:
- Identify indicator files (e.g.,
package.json) - List file patterns to edit
- List safe build commands
- Define deny rules for artifacts
- Add to
project_templates.json - Submit PR
- Fix typos or clarify instructions
- Add examples or use cases
- Improve error messages
- Translate to other languages
- Total Lines of Code: ~2,800
- CLI Tools Supported: 17
- Languages/Frameworks: 12
- Permission Profiles: 7
- Security Patterns: 80+
- Example Scenarios: 15+
MIT License - see LICENSE file for details.
- Claude Code by Anthropic
- Claude Code Community
- Skilz Marketplace - Universal skill installer
- All contributors and users
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Discord: Claude Code Community
- Marketplace: Skilz Listing
- More CLI tools (kubectl plugins, cloud CLIs)
- More language templates (Elixir, Haskell, Scala)
- Interactive setup wizard
- Permission diff viewer
- Integration with Claude Desktop
- Visual permission manager UI
- Team permission sharing
- Permission analytics
- AI-powered permission recommendations
- Automatic security audits
- Permission templates marketplace
- Enterprise policy manager
Made with care by the Claude Code Community