在 ~/.claude/settings.json(用户级)或 .claude/settings.json(项目级)中设置: 第一段permissions 设置权限,免得每次都问,很麻烦 第二段hooks,设置语音提醒,它在工作完成或者需要进行下一步工作确认时,会发出声音喊你啊。
{
"permissions": {
"allow": [
"Bash",
"Read",
"Write",
"Edit",
"Glob",
"Grep",
"WebFetch",
"WebSearch",
"Task",
"LSP",
"NotebookEdit"
]
},
"hooks": {
"Notification": [
{
"matcher": "",
"hooks": [
{
"type": "command",
"command": "powershell -Command \"Add-Type -AssemblyName System.Speech; (New-Object System.Speech.Synthesis.SpeechSynthesizer).Speak('please come back and confirm')\""
}
]
}
],
"Stop": [
{
"matcher": "",
"hooks": [
{
"type": "command",
"command": "powershell -Command \"Add-Type -AssemblyName System.Speech; (New-Object System.Speech.Synthesis.SpeechSynthesizer).Speak('Task completed')\""
}
]
}
]
}
}