Claude Code: Difference between revisions
Appearance
| Line 224: | Line 224: | ||
|Greg Baugues | |Greg Baugues | ||
|https://youtu.be/8T0kFSseB58 | |https://youtu.be/8T0kFSseB58 | ||
| | |https://www.haihai.ai/hooks/ | ||
|- | |- | ||
|H | |H | ||
Revision as of 16:00, 4 August 2025
| Other articles |
Installation on Ubuntu (WSL2)
sudo apt install npm mkdir -p ~/.npm-global npm config set prefix ~/.npm-global echo 'export PATH=~/.npm-global/bin:$PATH' >> ~/.bashrc # echo 'export PATH=~/.npm-global/bin:$PATH' >> ~/.bash_path source ~/.bashrc npm install -g @anthropic-ai/claude-code which claude claude doctor claude --version
Memory
Docs: https://docs.anthropic.com/en/docs/claude-code/memory
| file | |
|---|---|
| Project memory | $PROJECT_DIR/CLAUDE.md
|
| User memory | ~/.claude/CLAUDE.md
|
deprecated
|
Sub agents
| file | |
|---|---|
| User sub agents | ~/.claude/agents/
|
| Project sub agents | $PROJECT_DIR/.claude/agents/
|
- Example sub agents:
Custom commands
| file | |
|---|---|
| User commands | ~/.claude/commands/
|
| Project commands | $PROJECT_DIR/.claude/commands/
|
- Example custom commands:
MCP Server
claude mcp list claude mcp add <name> <command> [args...] claude mcp get my-server claude mcp remove my-server
| file | CLI switch | ||
|---|---|---|---|
| Local MCP Server | ~/.claude.json
|
default | -s local |
| Project MCP server | $PROJECT_DIR/.mcp.json
|
-s project | |
| User MCP Server | ~/.claude.json
|
-s user |
settings.json
Docs: https://docs.anthropic.com/en/docs/claude-code/settings
| file | scope | |
|---|---|---|
| User settings | ~/.claude/settings.json
|
|
| Project settings | $PROJECT_DIR/.claude/settings.json
|
all users |
| Project settings | $PROJECT_DIR/.claude/settings.local.json
|
local/personal only |
Example:
{
"permissions": {
"allow": [
"Bash(ls:*)"
],
"deny": []
}
}
Hook example:
"hooks": {
"UserPromptSubmit": [
{
"hooks": [
{
"type": "command",
"command": ".claude/hooks/prompt-validator.py"
}
]
}
]
}
Command line options
claude # interactive mode claude "task" # run single task claude -p "task" # run single task, print response, exit claude --dangerously-skip-permissions claude config list claude doctor claude update
Links & Videos & Learning
| Description | URL | Comment |
|---|---|---|
| Awesome Claude Code | https://github.com/hesreallyhim/awesome-claude-code | |
| Description | Channel | URL | Comments | |
|---|---|---|---|---|
| 1. | Basics | Matt Maher | https://youtu.be/T_IYHx-9VGU | |
| 2. | Best practices | Matt Maher | https://youtu.be/IUi--nVU4yA | |
| H | Hooks | IndyDevDan | https://youtu.be/J5B9UGTuNoM | |
| H | Hooks | Greg Baugues | https://youtu.be/8T0kFSseB58 | https://www.haihai.ai/hooks/ |
| H | Hooks 2 | IndyDevDan | https://youtu.be/9ijnN985O_c | GitHub |
| H | Hooks | Better Stack | https://youtu.be/Q4gsvJvRjCU | GitHub |
| S | Sub agents | Matt Maher | https://youtu.be/6MLyc3jYisQ | |
| S | Sub agents | IndyDevDan | https://youtu.be/7B2HJr0Y68g | |
| S | Sub agents | AI LABS | https://youtu.be/7Sx0o-41r2k | |
| AI Labs | https://youtu.be/6Rg5M69bMgQ | |||
| Workflow | AI Jason | https://youtu.be/UZb0if-7wGE | ||
| Best Practices | Patrick Ellis | https://youtu.be/hOqgFNlbrYE | ||
| Best Practices | Better Stack | https://youtu.be/Br5Ofobq6Is | ||
| Kimi K2 | Better Stack | https://youtu.be/av0Lsz3KkSE | ||
| Vibe Coding | Riley Brown | https://youtu.be/_GMtx9EsIKU | Build Lovable in 75min | |
| Vibe Coding | Sean Kochel | https://youtu.be/LWZrsF3kqI0 | Sketch to Mobile App in 21min |
- Channels
- Matt Maher: https://www.youtube.com/@MetalSole
- IndyDevDan: https://www.youtube.com/@indydevdan/
- AI Labs: https://www.youtube.com/@AILABS-393