mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-03-01 15:03:57 +08:00
docs: add VitePress documentation site
- Add docs directory with VitePress configuration - Add GitHub Actions workflow for docs build and deploy - Support bilingual (English/Chinese) documentation - Include search, custom theme, and responsive design
This commit is contained in:
131
docs/features/system-settings.md
Normal file
131
docs/features/system-settings.md
Normal file
@@ -0,0 +1,131 @@
|
||||
# System Settings
|
||||
|
||||
## One-Liner
|
||||
|
||||
**System Settings manages global and project-level configuration** — Controls hooks, agents, skills, and core system behavior.
|
||||
|
||||
---
|
||||
|
||||
## Configuration Files
|
||||
|
||||
| File | Scope | Purpose |
|
||||
|------|-------|---------|
|
||||
| `~/.claude/CLAUDE.md` | Global | Global instructions |
|
||||
| `.claude/CLAUDE.md` | Project | Project instructions |
|
||||
| `~/.claude/cli-tools.json` | Global | CLI tool config |
|
||||
| `.claude/settings.json` | Project | Project settings |
|
||||
| `.claude/settings.local.json` | Local | Local overrides |
|
||||
|
||||
---
|
||||
|
||||
## Settings Schema
|
||||
|
||||
```json
|
||||
{
|
||||
"permissions": {
|
||||
"allow": ["Bash(npm install)", "Bash(git status)"],
|
||||
"deny": ["Bash(rm -rf)"]
|
||||
},
|
||||
"env": {
|
||||
"ANTHROPIC_API_KEY": "your-key"
|
||||
},
|
||||
"enableAll": false,
|
||||
"autoCheck": true
|
||||
}
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Key Settings
|
||||
|
||||
### Permissions
|
||||
|
||||
```json
|
||||
{
|
||||
"permissions": {
|
||||
"allow": [
|
||||
"Bash(npm run*)",
|
||||
"Read(**)",
|
||||
"Edit(**/*.ts)"
|
||||
],
|
||||
"deny": [
|
||||
"Bash(rm -rf /*)"
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Hooks
|
||||
|
||||
```json
|
||||
{
|
||||
"hooks": {
|
||||
"PreToolUse": [
|
||||
{
|
||||
"matcher": "Bash",
|
||||
"hooks": [".claude/hooks/pre-bash.sh"]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### MCP Servers
|
||||
|
||||
```json
|
||||
{
|
||||
"mcpServers": {
|
||||
"ccw-tools": {
|
||||
"command": "node",
|
||||
"args": ["./mcp-server/dist/index.js"]
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Hook Configuration
|
||||
|
||||
Hooks are scripts that run at specific events:
|
||||
|
||||
| Event | When | Use Case |
|
||||
|-------|------|----------|
|
||||
| `PreToolUse` | Before tool execution | Validation, logging |
|
||||
| `PostToolUse` | After tool execution | Cleanup, notifications |
|
||||
| `Notification` | On notifications | Custom handlers |
|
||||
| `Stop` | On session end | Cleanup |
|
||||
|
||||
### Hook Example
|
||||
|
||||
```bash
|
||||
#!/bin/bash
|
||||
# .claude/hooks/pre-bash.sh
|
||||
echo "Executing: $1" >> ~/.claude/bash.log
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Agent Configuration
|
||||
|
||||
```json
|
||||
// .claude/agents/my-agent.md
|
||||
---
|
||||
description: Custom analysis agent
|
||||
model: claude-sonnet
|
||||
tools:
|
||||
- Read
|
||||
- Grep
|
||||
---
|
||||
|
||||
# Agent Instructions
|
||||
...
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Related Links
|
||||
|
||||
- [API Settings](/features/api-settings) - API configuration
|
||||
- [CLI Call](/features/cli) - Command invocation
|
||||
- [Dashboard](/features/dashboard) - Visual management
|
||||
Reference in New Issue
Block a user