[{"data":1,"prerenderedAt":1928},["ShallowReactive",2],{"guide:/guides/claude-code-notifications":3},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"tag":10,"date":11,"body":12,"_type":1922,"_id":1923,"_source":1924,"_file":1925,"_stem":1926,"_extension":1927},"/guides/claude-code-notifications","guides",false,"","How to get notified when Claude Code needs you (or finishes)","Stop tabbing back to check on Claude Code. Use the Notification and Stop hooks to get a desktop alert the moment a run needs your input or completes.","Notifications","2026-08-15",{"type":13,"children":14,"toc":1911},"root",[15,31,36,43,78,122,128,141,510,539,545,566,785,796,802,807,954,982,1002,1022,1028,1041,1203,1216,1363,1376,1382,1387,1506,1519,1525,1530,1643,1664,1670,1690,1862,1874,1880,1885,1905],{"type":16,"tag":17,"props":18,"children":19},"element","p",{},[20,23,29],{"type":21,"value":22},"text","Claude Code is at its best when you let it run: give it a task, switch to something else, come back when it is done. The catch is knowing ",{"type":16,"tag":24,"props":25,"children":26},"em",{},[27],{"type":21,"value":28},"when",{"type":21,"value":30}," to come back. Stare at the terminal and you have not really stepped away; ignore it and it sits waiting for a permission you never saw.",{"type":16,"tag":17,"props":32,"children":33},{},[34],{"type":21,"value":35},"You do not have to guess. Claude Code fires a hook the moment it needs you, and another when it finishes. Wire either one to a desktop notification and the terminal comes to you.",{"type":16,"tag":37,"props":38,"children":40},"h2",{"id":39},"the-two-events-that-matter",[41],{"type":21,"value":42},"The two events that matter",{"type":16,"tag":44,"props":45,"children":46},"ul",{},[47,64],{"type":16,"tag":48,"props":49,"children":50},"li",{},[51,62],{"type":16,"tag":52,"props":53,"children":54},"strong",{},[55],{"type":16,"tag":56,"props":57,"children":59},"code",{"className":58},[],[60],{"type":21,"value":61},"Notification",{"type":21,"value":63}," fires when Claude wants your attention. That means either a permission prompt it cannot answer on its own, or an input prompt that has been sitting idle for a while.",{"type":16,"tag":48,"props":65,"children":66},{},[67,76],{"type":16,"tag":52,"props":68,"children":69},{},[70],{"type":16,"tag":56,"props":71,"children":73},{"className":72},[],[74],{"type":21,"value":75},"Stop",{"type":21,"value":77}," fires when Claude finishes its turn and hands control back to you.",{"type":16,"tag":17,"props":79,"children":80},{},[81,83,88,90,95,97,103,105,111,113,120],{"type":21,"value":82},"Between them, they cover the two moments you actually care about: ",{"type":16,"tag":24,"props":84,"children":85},{},[86],{"type":21,"value":87},"it needs me now",{"type":21,"value":89},", and ",{"type":16,"tag":24,"props":91,"children":92},{},[93],{"type":21,"value":94},"it is done",{"type":21,"value":96},". Both are configured the same way, in a ",{"type":16,"tag":56,"props":98,"children":100},{"className":99},[],[101],{"type":21,"value":102},"settings.json",{"type":21,"value":104}," file under the ",{"type":16,"tag":56,"props":106,"children":108},{"className":107},[],[109],{"type":21,"value":110},"hooks",{"type":21,"value":112}," key. (If hooks are new to you, start with our ",{"type":16,"tag":114,"props":115,"children":117},"a",{"href":116},"/guides/claude-code-hooks",[118],{"type":21,"value":119},"complete guide to Claude Code hooks",{"type":21,"value":121},".)",{"type":16,"tag":37,"props":123,"children":125},{"id":124},"macos",[126],{"type":21,"value":127},"macOS",{"type":16,"tag":17,"props":129,"children":130},{},[131,133,139],{"type":21,"value":132},"macOS ships ",{"type":16,"tag":56,"props":134,"children":136},{"className":135},[],[137],{"type":21,"value":138},"osascript",{"type":21,"value":140},", which can post a real notification to Notification Center:",{"type":16,"tag":142,"props":143,"children":147},"pre",{"className":144,"code":145,"language":146,"meta":7,"style":7},"language-json shiki shiki-themes github-light github-dark","{\n  \"hooks\": {\n    \"Notification\": [\n      {\n        \"hooks\": [\n          { \"type\": \"command\", \"command\": \"osascript -e 'display notification \\\"Claude needs you\\\" with title \\\"Claude Code\\\" sound name \\\"Ping\\\"'\" }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          { \"type\": \"command\", \"command\": \"osascript -e 'display notification \\\"Run finished\\\" with title \\\"Claude Code\\\" sound name \\\"Glass\\\"'\" }\n        ]\n      }\n    ]\n  }\n}\n","json",[148],{"type":16,"tag":56,"props":149,"children":150},{"__ignoreMap":7},[151,163,178,192,201,214,317,326,335,344,357,365,377,467,475,483,492,501],{"type":16,"tag":152,"props":153,"children":156},"span",{"class":154,"line":155},"line",1,[157],{"type":16,"tag":152,"props":158,"children":160},{"style":159},"--shiki-default:#24292E;--shiki-dark:#E1E4E8",[161],{"type":21,"value":162},"{\n",{"type":16,"tag":152,"props":164,"children":166},{"class":154,"line":165},2,[167,173],{"type":16,"tag":152,"props":168,"children":170},{"style":169},"--shiki-default:#005CC5;--shiki-dark:#79B8FF",[171],{"type":21,"value":172},"  \"hooks\"",{"type":16,"tag":152,"props":174,"children":175},{"style":159},[176],{"type":21,"value":177},": {\n",{"type":16,"tag":152,"props":179,"children":181},{"class":154,"line":180},3,[182,187],{"type":16,"tag":152,"props":183,"children":184},{"style":169},[185],{"type":21,"value":186},"    \"Notification\"",{"type":16,"tag":152,"props":188,"children":189},{"style":159},[190],{"type":21,"value":191},": [\n",{"type":16,"tag":152,"props":193,"children":195},{"class":154,"line":194},4,[196],{"type":16,"tag":152,"props":197,"children":198},{"style":159},[199],{"type":21,"value":200},"      {\n",{"type":16,"tag":152,"props":202,"children":204},{"class":154,"line":203},5,[205,210],{"type":16,"tag":152,"props":206,"children":207},{"style":169},[208],{"type":21,"value":209},"        \"hooks\"",{"type":16,"tag":152,"props":211,"children":212},{"style":159},[213],{"type":21,"value":191},{"type":16,"tag":152,"props":215,"children":217},{"class":154,"line":216},6,[218,223,228,233,239,244,248,252,257,262,267,271,276,280,285,289,294,298,303,307,312],{"type":16,"tag":152,"props":219,"children":220},{"style":159},[221],{"type":21,"value":222},"          { ",{"type":16,"tag":152,"props":224,"children":225},{"style":169},[226],{"type":21,"value":227},"\"type\"",{"type":16,"tag":152,"props":229,"children":230},{"style":159},[231],{"type":21,"value":232},": ",{"type":16,"tag":152,"props":234,"children":236},{"style":235},"--shiki-default:#032F62;--shiki-dark:#9ECBFF",[237],{"type":21,"value":238},"\"command\"",{"type":16,"tag":152,"props":240,"children":241},{"style":159},[242],{"type":21,"value":243},", ",{"type":16,"tag":152,"props":245,"children":246},{"style":169},[247],{"type":21,"value":238},{"type":16,"tag":152,"props":249,"children":250},{"style":159},[251],{"type":21,"value":232},{"type":16,"tag":152,"props":253,"children":254},{"style":235},[255],{"type":21,"value":256},"\"osascript -e 'display notification ",{"type":16,"tag":152,"props":258,"children":259},{"style":169},[260],{"type":21,"value":261},"\\\"",{"type":16,"tag":152,"props":263,"children":264},{"style":235},[265],{"type":21,"value":266},"Claude needs you",{"type":16,"tag":152,"props":268,"children":269},{"style":169},[270],{"type":21,"value":261},{"type":16,"tag":152,"props":272,"children":273},{"style":235},[274],{"type":21,"value":275}," with title ",{"type":16,"tag":152,"props":277,"children":278},{"style":169},[279],{"type":21,"value":261},{"type":16,"tag":152,"props":281,"children":282},{"style":235},[283],{"type":21,"value":284},"Claude Code",{"type":16,"tag":152,"props":286,"children":287},{"style":169},[288],{"type":21,"value":261},{"type":16,"tag":152,"props":290,"children":291},{"style":235},[292],{"type":21,"value":293}," sound name ",{"type":16,"tag":152,"props":295,"children":296},{"style":169},[297],{"type":21,"value":261},{"type":16,"tag":152,"props":299,"children":300},{"style":235},[301],{"type":21,"value":302},"Ping",{"type":16,"tag":152,"props":304,"children":305},{"style":169},[306],{"type":21,"value":261},{"type":16,"tag":152,"props":308,"children":309},{"style":235},[310],{"type":21,"value":311},"'\"",{"type":16,"tag":152,"props":313,"children":314},{"style":159},[315],{"type":21,"value":316}," }\n",{"type":16,"tag":152,"props":318,"children":320},{"class":154,"line":319},7,[321],{"type":16,"tag":152,"props":322,"children":323},{"style":159},[324],{"type":21,"value":325},"        ]\n",{"type":16,"tag":152,"props":327,"children":329},{"class":154,"line":328},8,[330],{"type":16,"tag":152,"props":331,"children":332},{"style":159},[333],{"type":21,"value":334},"      }\n",{"type":16,"tag":152,"props":336,"children":338},{"class":154,"line":337},9,[339],{"type":16,"tag":152,"props":340,"children":341},{"style":159},[342],{"type":21,"value":343},"    ],\n",{"type":16,"tag":152,"props":345,"children":347},{"class":154,"line":346},10,[348,353],{"type":16,"tag":152,"props":349,"children":350},{"style":169},[351],{"type":21,"value":352},"    \"Stop\"",{"type":16,"tag":152,"props":354,"children":355},{"style":159},[356],{"type":21,"value":191},{"type":16,"tag":152,"props":358,"children":360},{"class":154,"line":359},11,[361],{"type":16,"tag":152,"props":362,"children":363},{"style":159},[364],{"type":21,"value":200},{"type":16,"tag":152,"props":366,"children":368},{"class":154,"line":367},12,[369,373],{"type":16,"tag":152,"props":370,"children":371},{"style":169},[372],{"type":21,"value":209},{"type":16,"tag":152,"props":374,"children":375},{"style":159},[376],{"type":21,"value":191},{"type":16,"tag":152,"props":378,"children":380},{"class":154,"line":379},13,[381,385,389,393,397,401,405,409,413,417,422,426,430,434,438,442,446,450,455,459,463],{"type":16,"tag":152,"props":382,"children":383},{"style":159},[384],{"type":21,"value":222},{"type":16,"tag":152,"props":386,"children":387},{"style":169},[388],{"type":21,"value":227},{"type":16,"tag":152,"props":390,"children":391},{"style":159},[392],{"type":21,"value":232},{"type":16,"tag":152,"props":394,"children":395},{"style":235},[396],{"type":21,"value":238},{"type":16,"tag":152,"props":398,"children":399},{"style":159},[400],{"type":21,"value":243},{"type":16,"tag":152,"props":402,"children":403},{"style":169},[404],{"type":21,"value":238},{"type":16,"tag":152,"props":406,"children":407},{"style":159},[408],{"type":21,"value":232},{"type":16,"tag":152,"props":410,"children":411},{"style":235},[412],{"type":21,"value":256},{"type":16,"tag":152,"props":414,"children":415},{"style":169},[416],{"type":21,"value":261},{"type":16,"tag":152,"props":418,"children":419},{"style":235},[420],{"type":21,"value":421},"Run finished",{"type":16,"tag":152,"props":423,"children":424},{"style":169},[425],{"type":21,"value":261},{"type":16,"tag":152,"props":427,"children":428},{"style":235},[429],{"type":21,"value":275},{"type":16,"tag":152,"props":431,"children":432},{"style":169},[433],{"type":21,"value":261},{"type":16,"tag":152,"props":435,"children":436},{"style":235},[437],{"type":21,"value":284},{"type":16,"tag":152,"props":439,"children":440},{"style":169},[441],{"type":21,"value":261},{"type":16,"tag":152,"props":443,"children":444},{"style":235},[445],{"type":21,"value":293},{"type":16,"tag":152,"props":447,"children":448},{"style":169},[449],{"type":21,"value":261},{"type":16,"tag":152,"props":451,"children":452},{"style":235},[453],{"type":21,"value":454},"Glass",{"type":16,"tag":152,"props":456,"children":457},{"style":169},[458],{"type":21,"value":261},{"type":16,"tag":152,"props":460,"children":461},{"style":235},[462],{"type":21,"value":311},{"type":16,"tag":152,"props":464,"children":465},{"style":159},[466],{"type":21,"value":316},{"type":16,"tag":152,"props":468,"children":470},{"class":154,"line":469},14,[471],{"type":16,"tag":152,"props":472,"children":473},{"style":159},[474],{"type":21,"value":325},{"type":16,"tag":152,"props":476,"children":478},{"class":154,"line":477},15,[479],{"type":16,"tag":152,"props":480,"children":481},{"style":159},[482],{"type":21,"value":334},{"type":16,"tag":152,"props":484,"children":486},{"class":154,"line":485},16,[487],{"type":16,"tag":152,"props":488,"children":489},{"style":159},[490],{"type":21,"value":491},"    ]\n",{"type":16,"tag":152,"props":493,"children":495},{"class":154,"line":494},17,[496],{"type":16,"tag":152,"props":497,"children":498},{"style":159},[499],{"type":21,"value":500},"  }\n",{"type":16,"tag":152,"props":502,"children":504},{"class":154,"line":503},18,[505],{"type":16,"tag":152,"props":506,"children":507},{"style":159},[508],{"type":21,"value":509},"}\n",{"type":16,"tag":17,"props":511,"children":512},{},[513,515,521,523,529,531,537],{"type":21,"value":514},"The ",{"type":16,"tag":56,"props":516,"children":518},{"className":517},[],[519],{"type":21,"value":520},"sound name",{"type":21,"value":522}," part rings a system sound, so you get an audible cue even if you are not looking at the screen. If you want alerts that stay on screen until you dismiss them, install ",{"type":16,"tag":56,"props":524,"children":526},{"className":525},[],[527],{"type":21,"value":528},"terminal-notifier",{"type":21,"value":530}," and use ",{"type":16,"tag":56,"props":532,"children":534},{"className":533},[],[535],{"type":21,"value":536},"terminal-notifier -title 'Claude Code' -message 'Claude needs you'",{"type":21,"value":538}," instead.",{"type":16,"tag":37,"props":540,"children":542},{"id":541},"linux",[543],{"type":21,"value":544},"Linux",{"type":16,"tag":17,"props":546,"children":547},{},[548,550,556,558,564],{"type":21,"value":549},"On most desktops, ",{"type":16,"tag":56,"props":551,"children":553},{"className":552},[],[554],{"type":21,"value":555},"notify-send",{"type":21,"value":557}," is available (from ",{"type":16,"tag":56,"props":559,"children":561},{"className":560},[],[562],{"type":21,"value":563},"libnotify",{"type":21,"value":565},"):",{"type":16,"tag":142,"props":567,"children":569},{"className":144,"code":568,"language":146,"meta":7,"style":7},"{\n  \"hooks\": {\n    \"Notification\": [\n      {\n        \"hooks\": [\n          { \"type\": \"command\", \"command\": \"notify-send -u critical 'Claude Code' 'Claude needs you'\" }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          { \"type\": \"command\", \"command\": \"notify-send 'Claude Code' 'Run finished'\" }\n        ]\n      }\n    ]\n  }\n}\n",[570],{"type":16,"tag":56,"props":571,"children":572},{"__ignoreMap":7},[573,580,591,602,609,620,660,667,674,681,692,699,710,750,757,764,771,778],{"type":16,"tag":152,"props":574,"children":575},{"class":154,"line":155},[576],{"type":16,"tag":152,"props":577,"children":578},{"style":159},[579],{"type":21,"value":162},{"type":16,"tag":152,"props":581,"children":582},{"class":154,"line":165},[583,587],{"type":16,"tag":152,"props":584,"children":585},{"style":169},[586],{"type":21,"value":172},{"type":16,"tag":152,"props":588,"children":589},{"style":159},[590],{"type":21,"value":177},{"type":16,"tag":152,"props":592,"children":593},{"class":154,"line":180},[594,598],{"type":16,"tag":152,"props":595,"children":596},{"style":169},[597],{"type":21,"value":186},{"type":16,"tag":152,"props":599,"children":600},{"style":159},[601],{"type":21,"value":191},{"type":16,"tag":152,"props":603,"children":604},{"class":154,"line":194},[605],{"type":16,"tag":152,"props":606,"children":607},{"style":159},[608],{"type":21,"value":200},{"type":16,"tag":152,"props":610,"children":611},{"class":154,"line":203},[612,616],{"type":16,"tag":152,"props":613,"children":614},{"style":169},[615],{"type":21,"value":209},{"type":16,"tag":152,"props":617,"children":618},{"style":159},[619],{"type":21,"value":191},{"type":16,"tag":152,"props":621,"children":622},{"class":154,"line":216},[623,627,631,635,639,643,647,651,656],{"type":16,"tag":152,"props":624,"children":625},{"style":159},[626],{"type":21,"value":222},{"type":16,"tag":152,"props":628,"children":629},{"style":169},[630],{"type":21,"value":227},{"type":16,"tag":152,"props":632,"children":633},{"style":159},[634],{"type":21,"value":232},{"type":16,"tag":152,"props":636,"children":637},{"style":235},[638],{"type":21,"value":238},{"type":16,"tag":152,"props":640,"children":641},{"style":159},[642],{"type":21,"value":243},{"type":16,"tag":152,"props":644,"children":645},{"style":169},[646],{"type":21,"value":238},{"type":16,"tag":152,"props":648,"children":649},{"style":159},[650],{"type":21,"value":232},{"type":16,"tag":152,"props":652,"children":653},{"style":235},[654],{"type":21,"value":655},"\"notify-send -u critical 'Claude Code' 'Claude needs you'\"",{"type":16,"tag":152,"props":657,"children":658},{"style":159},[659],{"type":21,"value":316},{"type":16,"tag":152,"props":661,"children":662},{"class":154,"line":319},[663],{"type":16,"tag":152,"props":664,"children":665},{"style":159},[666],{"type":21,"value":325},{"type":16,"tag":152,"props":668,"children":669},{"class":154,"line":328},[670],{"type":16,"tag":152,"props":671,"children":672},{"style":159},[673],{"type":21,"value":334},{"type":16,"tag":152,"props":675,"children":676},{"class":154,"line":337},[677],{"type":16,"tag":152,"props":678,"children":679},{"style":159},[680],{"type":21,"value":343},{"type":16,"tag":152,"props":682,"children":683},{"class":154,"line":346},[684,688],{"type":16,"tag":152,"props":685,"children":686},{"style":169},[687],{"type":21,"value":352},{"type":16,"tag":152,"props":689,"children":690},{"style":159},[691],{"type":21,"value":191},{"type":16,"tag":152,"props":693,"children":694},{"class":154,"line":359},[695],{"type":16,"tag":152,"props":696,"children":697},{"style":159},[698],{"type":21,"value":200},{"type":16,"tag":152,"props":700,"children":701},{"class":154,"line":367},[702,706],{"type":16,"tag":152,"props":703,"children":704},{"style":169},[705],{"type":21,"value":209},{"type":16,"tag":152,"props":707,"children":708},{"style":159},[709],{"type":21,"value":191},{"type":16,"tag":152,"props":711,"children":712},{"class":154,"line":379},[713,717,721,725,729,733,737,741,746],{"type":16,"tag":152,"props":714,"children":715},{"style":159},[716],{"type":21,"value":222},{"type":16,"tag":152,"props":718,"children":719},{"style":169},[720],{"type":21,"value":227},{"type":16,"tag":152,"props":722,"children":723},{"style":159},[724],{"type":21,"value":232},{"type":16,"tag":152,"props":726,"children":727},{"style":235},[728],{"type":21,"value":238},{"type":16,"tag":152,"props":730,"children":731},{"style":159},[732],{"type":21,"value":243},{"type":16,"tag":152,"props":734,"children":735},{"style":169},[736],{"type":21,"value":238},{"type":16,"tag":152,"props":738,"children":739},{"style":159},[740],{"type":21,"value":232},{"type":16,"tag":152,"props":742,"children":743},{"style":235},[744],{"type":21,"value":745},"\"notify-send 'Claude Code' 'Run finished'\"",{"type":16,"tag":152,"props":747,"children":748},{"style":159},[749],{"type":21,"value":316},{"type":16,"tag":152,"props":751,"children":752},{"class":154,"line":469},[753],{"type":16,"tag":152,"props":754,"children":755},{"style":159},[756],{"type":21,"value":325},{"type":16,"tag":152,"props":758,"children":759},{"class":154,"line":477},[760],{"type":16,"tag":152,"props":761,"children":762},{"style":159},[763],{"type":21,"value":334},{"type":16,"tag":152,"props":765,"children":766},{"class":154,"line":485},[767],{"type":16,"tag":152,"props":768,"children":769},{"style":159},[770],{"type":21,"value":491},{"type":16,"tag":152,"props":772,"children":773},{"class":154,"line":494},[774],{"type":16,"tag":152,"props":775,"children":776},{"style":159},[777],{"type":21,"value":500},{"type":16,"tag":152,"props":779,"children":780},{"class":154,"line":503},[781],{"type":16,"tag":152,"props":782,"children":783},{"style":159},[784],{"type":21,"value":509},{"type":16,"tag":17,"props":786,"children":787},{},[788,794],{"type":16,"tag":56,"props":789,"children":791},{"className":790},[],[792],{"type":21,"value":793},"-u critical",{"type":21,"value":795}," keeps the \"needs you\" alert on screen until you dismiss it, which is what you want for something that is blocking.",{"type":16,"tag":37,"props":797,"children":799},{"id":798},"windows-and-wsl",[800],{"type":21,"value":801},"Windows and WSL",{"type":16,"tag":17,"props":803,"children":804},{},[805],{"type":21,"value":806},"On Windows, PowerShell can raise a toast through the BurntToast module, but the dependency-free option is a message box:",{"type":16,"tag":142,"props":808,"children":810},{"className":144,"code":809,"language":146,"meta":7,"style":7},"{\n  \"hooks\": {\n    \"Stop\": [\n      {\n        \"hooks\": [\n          { \"type\": \"command\", \"command\": \"powershell -c \\\"Add-Type -AssemblyName System.Windows.Forms; [System.Windows.Forms.MessageBox]::Show('Run finished','Claude Code')\\\"\" }\n        ]\n      }\n    ]\n  }\n}\n",[811],{"type":16,"tag":56,"props":812,"children":813},{"__ignoreMap":7},[814,821,832,843,850,861,919,926,933,940,947],{"type":16,"tag":152,"props":815,"children":816},{"class":154,"line":155},[817],{"type":16,"tag":152,"props":818,"children":819},{"style":159},[820],{"type":21,"value":162},{"type":16,"tag":152,"props":822,"children":823},{"class":154,"line":165},[824,828],{"type":16,"tag":152,"props":825,"children":826},{"style":169},[827],{"type":21,"value":172},{"type":16,"tag":152,"props":829,"children":830},{"style":159},[831],{"type":21,"value":177},{"type":16,"tag":152,"props":833,"children":834},{"class":154,"line":180},[835,839],{"type":16,"tag":152,"props":836,"children":837},{"style":169},[838],{"type":21,"value":352},{"type":16,"tag":152,"props":840,"children":841},{"style":159},[842],{"type":21,"value":191},{"type":16,"tag":152,"props":844,"children":845},{"class":154,"line":194},[846],{"type":16,"tag":152,"props":847,"children":848},{"style":159},[849],{"type":21,"value":200},{"type":16,"tag":152,"props":851,"children":852},{"class":154,"line":203},[853,857],{"type":16,"tag":152,"props":854,"children":855},{"style":169},[856],{"type":21,"value":209},{"type":16,"tag":152,"props":858,"children":859},{"style":159},[860],{"type":21,"value":191},{"type":16,"tag":152,"props":862,"children":863},{"class":154,"line":216},[864,868,872,876,880,884,888,892,897,901,906,910,915],{"type":16,"tag":152,"props":865,"children":866},{"style":159},[867],{"type":21,"value":222},{"type":16,"tag":152,"props":869,"children":870},{"style":169},[871],{"type":21,"value":227},{"type":16,"tag":152,"props":873,"children":874},{"style":159},[875],{"type":21,"value":232},{"type":16,"tag":152,"props":877,"children":878},{"style":235},[879],{"type":21,"value":238},{"type":16,"tag":152,"props":881,"children":882},{"style":159},[883],{"type":21,"value":243},{"type":16,"tag":152,"props":885,"children":886},{"style":169},[887],{"type":21,"value":238},{"type":16,"tag":152,"props":889,"children":890},{"style":159},[891],{"type":21,"value":232},{"type":16,"tag":152,"props":893,"children":894},{"style":235},[895],{"type":21,"value":896},"\"powershell -c ",{"type":16,"tag":152,"props":898,"children":899},{"style":169},[900],{"type":21,"value":261},{"type":16,"tag":152,"props":902,"children":903},{"style":235},[904],{"type":21,"value":905},"Add-Type -AssemblyName System.Windows.Forms; [System.Windows.Forms.MessageBox]::Show('Run finished','Claude Code')",{"type":16,"tag":152,"props":907,"children":908},{"style":169},[909],{"type":21,"value":261},{"type":16,"tag":152,"props":911,"children":912},{"style":235},[913],{"type":21,"value":914},"\"",{"type":16,"tag":152,"props":916,"children":917},{"style":159},[918],{"type":21,"value":316},{"type":16,"tag":152,"props":920,"children":921},{"class":154,"line":319},[922],{"type":16,"tag":152,"props":923,"children":924},{"style":159},[925],{"type":21,"value":325},{"type":16,"tag":152,"props":927,"children":928},{"class":154,"line":328},[929],{"type":16,"tag":152,"props":930,"children":931},{"style":159},[932],{"type":21,"value":334},{"type":16,"tag":152,"props":934,"children":935},{"class":154,"line":337},[936],{"type":16,"tag":152,"props":937,"children":938},{"style":159},[939],{"type":21,"value":491},{"type":16,"tag":152,"props":941,"children":942},{"class":154,"line":346},[943],{"type":16,"tag":152,"props":944,"children":945},{"style":159},[946],{"type":21,"value":500},{"type":16,"tag":152,"props":948,"children":949},{"class":154,"line":359},[950],{"type":16,"tag":152,"props":951,"children":952},{"style":159},[953],{"type":21,"value":509},{"type":16,"tag":17,"props":955,"children":956},{},[957,958,964,966,972,974,980],{"type":21,"value":514},{"type":16,"tag":56,"props":959,"children":961},{"className":960},[],[962],{"type":21,"value":963},"Add-Type",{"type":21,"value":965}," is not optional. ",{"type":16,"tag":56,"props":967,"children":969},{"className":968},[],[970],{"type":21,"value":971},"System.Windows.Forms",{"type":21,"value":973}," is not loaded in a fresh PowerShell session, so without it you get ",{"type":16,"tag":56,"props":975,"children":977},{"className":976},[],[978],{"type":21,"value":979},"Unable to find type [System.Windows.Forms.MessageBox]",{"type":21,"value":981}," and no box.",{"type":16,"tag":17,"props":983,"children":984},{},[985,987,992,994,1000],{"type":21,"value":986},"One thing to know before you wire this to anything other than ",{"type":16,"tag":56,"props":988,"children":990},{"className":989},[],[991],{"type":21,"value":75},{"type":21,"value":993},": the dialog is modal, so the hook does not return until you click OK. That is fine at the end of a run and a bad idea on ",{"type":16,"tag":56,"props":995,"children":997},{"className":996},[],[998],{"type":21,"value":999},"PreToolUse",{"type":21,"value":1001},", where it would hold up the tool call until you noticed.",{"type":16,"tag":17,"props":1003,"children":1004},{},[1005,1007,1012,1014,1020],{"type":21,"value":1006},"Running Claude Code inside WSL? ",{"type":16,"tag":56,"props":1008,"children":1010},{"className":1009},[],[1011],{"type":21,"value":555},{"type":21,"value":1013}," will not reach the Windows desktop unless you have WSLg. Call PowerShell from the Linux side instead: ",{"type":16,"tag":56,"props":1015,"children":1017},{"className":1016},[],[1018],{"type":21,"value":1019},"powershell.exe -c \"...\"",{"type":21,"value":1021}," works from any WSL shell.",{"type":16,"tag":37,"props":1023,"children":1025},{"id":1024},"say-which-project-pinged",[1026],{"type":21,"value":1027},"Say which project pinged",{"type":16,"tag":17,"props":1029,"children":1030},{},[1031,1033,1039],{"type":21,"value":1032},"A notification that says \"Claude needs you\" is useless once you run more than one session. The payload arriving on ",{"type":16,"tag":56,"props":1034,"children":1036},{"className":1035},[],[1037],{"type":21,"value":1038},"stdin",{"type":21,"value":1040}," carries the session's working directory, so a two-line script can name the project:",{"type":16,"tag":142,"props":1042,"children":1046},{"className":1043,"code":1044,"language":1045,"meta":7,"style":7},"language-bash shiki shiki-themes github-light github-dark","#!/usr/bin/env bash\n# .claude/hooks/notify.sh\npayload=$(cat)\nproject=$(basename \"$(echo \"$payload\" | jq -r '.cwd')\")\nnotify-send -u critical \"Claude Code\" \"$project needs you\"\n","bash",[1047],{"type":16,"tag":56,"props":1048,"children":1049},{"__ignoreMap":7},[1050,1059,1067,1097,1167],{"type":16,"tag":152,"props":1051,"children":1052},{"class":154,"line":155},[1053],{"type":16,"tag":152,"props":1054,"children":1056},{"style":1055},"--shiki-default:#6A737D;--shiki-dark:#6A737D",[1057],{"type":21,"value":1058},"#!/usr/bin/env bash\n",{"type":16,"tag":152,"props":1060,"children":1061},{"class":154,"line":165},[1062],{"type":16,"tag":152,"props":1063,"children":1064},{"style":1055},[1065],{"type":21,"value":1066},"# .claude/hooks/notify.sh\n",{"type":16,"tag":152,"props":1068,"children":1069},{"class":154,"line":180},[1070,1075,1081,1086,1092],{"type":16,"tag":152,"props":1071,"children":1072},{"style":159},[1073],{"type":21,"value":1074},"payload",{"type":16,"tag":152,"props":1076,"children":1078},{"style":1077},"--shiki-default:#D73A49;--shiki-dark:#F97583",[1079],{"type":21,"value":1080},"=",{"type":16,"tag":152,"props":1082,"children":1083},{"style":159},[1084],{"type":21,"value":1085},"$(",{"type":16,"tag":152,"props":1087,"children":1089},{"style":1088},"--shiki-default:#6F42C1;--shiki-dark:#B392F0",[1090],{"type":21,"value":1091},"cat",{"type":16,"tag":152,"props":1093,"children":1094},{"style":159},[1095],{"type":21,"value":1096},")\n",{"type":16,"tag":152,"props":1098,"children":1099},{"class":154,"line":194},[1100,1105,1109,1113,1118,1123,1128,1133,1138,1143,1148,1153,1158,1163],{"type":16,"tag":152,"props":1101,"children":1102},{"style":159},[1103],{"type":21,"value":1104},"project",{"type":16,"tag":152,"props":1106,"children":1107},{"style":1077},[1108],{"type":21,"value":1080},{"type":16,"tag":152,"props":1110,"children":1111},{"style":159},[1112],{"type":21,"value":1085},{"type":16,"tag":152,"props":1114,"children":1115},{"style":1088},[1116],{"type":21,"value":1117},"basename",{"type":16,"tag":152,"props":1119,"children":1120},{"style":235},[1121],{"type":21,"value":1122}," \"$(",{"type":16,"tag":152,"props":1124,"children":1125},{"style":169},[1126],{"type":21,"value":1127},"echo",{"type":16,"tag":152,"props":1129,"children":1130},{"style":235},[1131],{"type":21,"value":1132}," \"",{"type":16,"tag":152,"props":1134,"children":1135},{"style":159},[1136],{"type":21,"value":1137},"$payload",{"type":16,"tag":152,"props":1139,"children":1140},{"style":235},[1141],{"type":21,"value":1142},"\" ",{"type":16,"tag":152,"props":1144,"children":1145},{"style":1077},[1146],{"type":21,"value":1147},"|",{"type":16,"tag":152,"props":1149,"children":1150},{"style":1088},[1151],{"type":21,"value":1152}," jq",{"type":16,"tag":152,"props":1154,"children":1155},{"style":169},[1156],{"type":21,"value":1157}," -r",{"type":16,"tag":152,"props":1159,"children":1160},{"style":235},[1161],{"type":21,"value":1162}," '.cwd')\"",{"type":16,"tag":152,"props":1164,"children":1165},{"style":159},[1166],{"type":21,"value":1096},{"type":16,"tag":152,"props":1168,"children":1169},{"class":154,"line":203},[1170,1174,1179,1184,1189,1193,1198],{"type":16,"tag":152,"props":1171,"children":1172},{"style":1088},[1173],{"type":21,"value":555},{"type":16,"tag":152,"props":1175,"children":1176},{"style":169},[1177],{"type":21,"value":1178}," -u",{"type":16,"tag":152,"props":1180,"children":1181},{"style":235},[1182],{"type":21,"value":1183}," critical",{"type":16,"tag":152,"props":1185,"children":1186},{"style":235},[1187],{"type":21,"value":1188}," \"Claude Code\"",{"type":16,"tag":152,"props":1190,"children":1191},{"style":235},[1192],{"type":21,"value":1132},{"type":16,"tag":152,"props":1194,"children":1195},{"style":159},[1196],{"type":21,"value":1197},"$project",{"type":16,"tag":152,"props":1199,"children":1200},{"style":235},[1201],{"type":21,"value":1202}," needs you\"\n",{"type":16,"tag":17,"props":1204,"children":1205},{},[1206,1208,1214],{"type":21,"value":1207},"Point the hook at it, and use ",{"type":16,"tag":56,"props":1209,"children":1211},{"className":1210},[],[1212],{"type":21,"value":1213},"$CLAUDE_PROJECT_DIR",{"type":21,"value":1215}," so the path resolves from any subdirectory:",{"type":16,"tag":142,"props":1217,"children":1219},{"className":144,"code":1218,"language":146,"meta":7,"style":7},"{\n  \"hooks\": {\n    \"Notification\": [\n      {\n        \"hooks\": [\n          { \"type\": \"command\", \"command\": \"$CLAUDE_PROJECT_DIR/.claude/hooks/notify.sh\", \"timeout\": 10 }\n        ]\n      }\n    ]\n  }\n}\n",[1220],{"type":16,"tag":56,"props":1221,"children":1222},{"__ignoreMap":7},[1223,1230,1241,1252,1259,1270,1328,1335,1342,1349,1356],{"type":16,"tag":152,"props":1224,"children":1225},{"class":154,"line":155},[1226],{"type":16,"tag":152,"props":1227,"children":1228},{"style":159},[1229],{"type":21,"value":162},{"type":16,"tag":152,"props":1231,"children":1232},{"class":154,"line":165},[1233,1237],{"type":16,"tag":152,"props":1234,"children":1235},{"style":169},[1236],{"type":21,"value":172},{"type":16,"tag":152,"props":1238,"children":1239},{"style":159},[1240],{"type":21,"value":177},{"type":16,"tag":152,"props":1242,"children":1243},{"class":154,"line":180},[1244,1248],{"type":16,"tag":152,"props":1245,"children":1246},{"style":169},[1247],{"type":21,"value":186},{"type":16,"tag":152,"props":1249,"children":1250},{"style":159},[1251],{"type":21,"value":191},{"type":16,"tag":152,"props":1253,"children":1254},{"class":154,"line":194},[1255],{"type":16,"tag":152,"props":1256,"children":1257},{"style":159},[1258],{"type":21,"value":200},{"type":16,"tag":152,"props":1260,"children":1261},{"class":154,"line":203},[1262,1266],{"type":16,"tag":152,"props":1263,"children":1264},{"style":169},[1265],{"type":21,"value":209},{"type":16,"tag":152,"props":1267,"children":1268},{"style":159},[1269],{"type":21,"value":191},{"type":16,"tag":152,"props":1271,"children":1272},{"class":154,"line":216},[1273,1277,1281,1285,1289,1293,1297,1301,1306,1310,1315,1319,1324],{"type":16,"tag":152,"props":1274,"children":1275},{"style":159},[1276],{"type":21,"value":222},{"type":16,"tag":152,"props":1278,"children":1279},{"style":169},[1280],{"type":21,"value":227},{"type":16,"tag":152,"props":1282,"children":1283},{"style":159},[1284],{"type":21,"value":232},{"type":16,"tag":152,"props":1286,"children":1287},{"style":235},[1288],{"type":21,"value":238},{"type":16,"tag":152,"props":1290,"children":1291},{"style":159},[1292],{"type":21,"value":243},{"type":16,"tag":152,"props":1294,"children":1295},{"style":169},[1296],{"type":21,"value":238},{"type":16,"tag":152,"props":1298,"children":1299},{"style":159},[1300],{"type":21,"value":232},{"type":16,"tag":152,"props":1302,"children":1303},{"style":235},[1304],{"type":21,"value":1305},"\"$CLAUDE_PROJECT_DIR/.claude/hooks/notify.sh\"",{"type":16,"tag":152,"props":1307,"children":1308},{"style":159},[1309],{"type":21,"value":243},{"type":16,"tag":152,"props":1311,"children":1312},{"style":169},[1313],{"type":21,"value":1314},"\"timeout\"",{"type":16,"tag":152,"props":1316,"children":1317},{"style":159},[1318],{"type":21,"value":232},{"type":16,"tag":152,"props":1320,"children":1321},{"style":169},[1322],{"type":21,"value":1323},"10",{"type":16,"tag":152,"props":1325,"children":1326},{"style":159},[1327],{"type":21,"value":316},{"type":16,"tag":152,"props":1329,"children":1330},{"class":154,"line":319},[1331],{"type":16,"tag":152,"props":1332,"children":1333},{"style":159},[1334],{"type":21,"value":325},{"type":16,"tag":152,"props":1336,"children":1337},{"class":154,"line":328},[1338],{"type":16,"tag":152,"props":1339,"children":1340},{"style":159},[1341],{"type":21,"value":334},{"type":16,"tag":152,"props":1343,"children":1344},{"class":154,"line":337},[1345],{"type":16,"tag":152,"props":1346,"children":1347},{"style":159},[1348],{"type":21,"value":491},{"type":16,"tag":152,"props":1350,"children":1351},{"class":154,"line":346},[1352],{"type":16,"tag":152,"props":1353,"children":1354},{"style":159},[1355],{"type":21,"value":500},{"type":16,"tag":152,"props":1357,"children":1358},{"class":154,"line":359},[1359],{"type":16,"tag":152,"props":1360,"children":1361},{"style":159},[1362],{"type":21,"value":509},{"type":16,"tag":17,"props":1364,"children":1365},{},[1366,1368,1374],{"type":21,"value":1367},"The same payload also carries ",{"type":16,"tag":56,"props":1369,"children":1371},{"className":1370},[],[1372],{"type":21,"value":1373},"session_id",{"type":21,"value":1375},", if you would rather key your notifications on the session than on the folder.",{"type":16,"tag":37,"props":1377,"children":1379},{"id":1378},"just-want-a-sound",[1380],{"type":21,"value":1381},"Just want a sound?",{"type":16,"tag":17,"props":1383,"children":1384},{},[1385],{"type":21,"value":1386},"You do not need a full notification. A single bell in the terminal is often enough:",{"type":16,"tag":142,"props":1388,"children":1390},{"className":144,"code":1389,"language":146,"meta":7,"style":7},"{\n  \"hooks\": {\n    \"Stop\": [\n      { \"hooks\": [{ \"type\": \"command\", \"command\": \"printf '\\\\a'\" }] }\n    ]\n  }\n}\n",[1391],{"type":16,"tag":56,"props":1392,"children":1393},{"__ignoreMap":7},[1394,1401,1412,1423,1485,1492,1499],{"type":16,"tag":152,"props":1395,"children":1396},{"class":154,"line":155},[1397],{"type":16,"tag":152,"props":1398,"children":1399},{"style":159},[1400],{"type":21,"value":162},{"type":16,"tag":152,"props":1402,"children":1403},{"class":154,"line":165},[1404,1408],{"type":16,"tag":152,"props":1405,"children":1406},{"style":169},[1407],{"type":21,"value":172},{"type":16,"tag":152,"props":1409,"children":1410},{"style":159},[1411],{"type":21,"value":177},{"type":16,"tag":152,"props":1413,"children":1414},{"class":154,"line":180},[1415,1419],{"type":16,"tag":152,"props":1416,"children":1417},{"style":169},[1418],{"type":21,"value":352},{"type":16,"tag":152,"props":1420,"children":1421},{"style":159},[1422],{"type":21,"value":191},{"type":16,"tag":152,"props":1424,"children":1425},{"class":154,"line":194},[1426,1431,1436,1441,1445,1449,1453,1457,1461,1465,1470,1475,1480],{"type":16,"tag":152,"props":1427,"children":1428},{"style":159},[1429],{"type":21,"value":1430},"      { ",{"type":16,"tag":152,"props":1432,"children":1433},{"style":169},[1434],{"type":21,"value":1435},"\"hooks\"",{"type":16,"tag":152,"props":1437,"children":1438},{"style":159},[1439],{"type":21,"value":1440},": [{ ",{"type":16,"tag":152,"props":1442,"children":1443},{"style":169},[1444],{"type":21,"value":227},{"type":16,"tag":152,"props":1446,"children":1447},{"style":159},[1448],{"type":21,"value":232},{"type":16,"tag":152,"props":1450,"children":1451},{"style":235},[1452],{"type":21,"value":238},{"type":16,"tag":152,"props":1454,"children":1455},{"style":159},[1456],{"type":21,"value":243},{"type":16,"tag":152,"props":1458,"children":1459},{"style":169},[1460],{"type":21,"value":238},{"type":16,"tag":152,"props":1462,"children":1463},{"style":159},[1464],{"type":21,"value":232},{"type":16,"tag":152,"props":1466,"children":1467},{"style":235},[1468],{"type":21,"value":1469},"\"printf '",{"type":16,"tag":152,"props":1471,"children":1472},{"style":169},[1473],{"type":21,"value":1474},"\\\\",{"type":16,"tag":152,"props":1476,"children":1477},{"style":235},[1478],{"type":21,"value":1479},"a'\"",{"type":16,"tag":152,"props":1481,"children":1482},{"style":159},[1483],{"type":21,"value":1484}," }] }\n",{"type":16,"tag":152,"props":1486,"children":1487},{"class":154,"line":203},[1488],{"type":16,"tag":152,"props":1489,"children":1490},{"style":159},[1491],{"type":21,"value":491},{"type":16,"tag":152,"props":1493,"children":1494},{"class":154,"line":216},[1495],{"type":16,"tag":152,"props":1496,"children":1497},{"style":159},[1498],{"type":21,"value":500},{"type":16,"tag":152,"props":1500,"children":1501},{"class":154,"line":319},[1502],{"type":16,"tag":152,"props":1503,"children":1504},{"style":159},[1505],{"type":21,"value":509},{"type":16,"tag":17,"props":1507,"children":1508},{},[1509,1511,1517],{"type":21,"value":1510},"There is a per-platform walkthrough in ",{"type":16,"tag":114,"props":1512,"children":1514},{"href":1513},"/guides/claude-code-sound-when-done",[1515],{"type":21,"value":1516},"play a sound when Claude Code finishes",{"type":21,"value":1518},".",{"type":16,"tag":37,"props":1520,"children":1522},{"id":1521},"or-let-your-terminal-carry-the-alert",[1523],{"type":21,"value":1524},"Or let your terminal carry the alert",{"type":16,"tag":17,"props":1526,"children":1527},{},[1528],{"type":21,"value":1529},"A desktop notification is not the only option, and in a terminal-heavy setup it is often not the best one. Ringing the bell from the hook lets your multiplexer flag the exact window the event came from:",{"type":16,"tag":142,"props":1531,"children":1533},{"className":144,"code":1532,"language":146,"meta":7,"style":7},"{\n  \"hooks\": {\n    \"Notification\": [\n      { \"hooks\": [{ \"type\": \"command\", \"command\": \"printf '\\\\a' > /dev/tty\" }] }\n    ]\n  }\n}\n",[1534],{"type":16,"tag":56,"props":1535,"children":1536},{"__ignoreMap":7},[1537,1544,1555,1566,1622,1629,1636],{"type":16,"tag":152,"props":1538,"children":1539},{"class":154,"line":155},[1540],{"type":16,"tag":152,"props":1541,"children":1542},{"style":159},[1543],{"type":21,"value":162},{"type":16,"tag":152,"props":1545,"children":1546},{"class":154,"line":165},[1547,1551],{"type":16,"tag":152,"props":1548,"children":1549},{"style":169},[1550],{"type":21,"value":172},{"type":16,"tag":152,"props":1552,"children":1553},{"style":159},[1554],{"type":21,"value":177},{"type":16,"tag":152,"props":1556,"children":1557},{"class":154,"line":180},[1558,1562],{"type":16,"tag":152,"props":1559,"children":1560},{"style":169},[1561],{"type":21,"value":186},{"type":16,"tag":152,"props":1563,"children":1564},{"style":159},[1565],{"type":21,"value":191},{"type":16,"tag":152,"props":1567,"children":1568},{"class":154,"line":194},[1569,1573,1577,1581,1585,1589,1593,1597,1601,1605,1609,1613,1618],{"type":16,"tag":152,"props":1570,"children":1571},{"style":159},[1572],{"type":21,"value":1430},{"type":16,"tag":152,"props":1574,"children":1575},{"style":169},[1576],{"type":21,"value":1435},{"type":16,"tag":152,"props":1578,"children":1579},{"style":159},[1580],{"type":21,"value":1440},{"type":16,"tag":152,"props":1582,"children":1583},{"style":169},[1584],{"type":21,"value":227},{"type":16,"tag":152,"props":1586,"children":1587},{"style":159},[1588],{"type":21,"value":232},{"type":16,"tag":152,"props":1590,"children":1591},{"style":235},[1592],{"type":21,"value":238},{"type":16,"tag":152,"props":1594,"children":1595},{"style":159},[1596],{"type":21,"value":243},{"type":16,"tag":152,"props":1598,"children":1599},{"style":169},[1600],{"type":21,"value":238},{"type":16,"tag":152,"props":1602,"children":1603},{"style":159},[1604],{"type":21,"value":232},{"type":16,"tag":152,"props":1606,"children":1607},{"style":235},[1608],{"type":21,"value":1469},{"type":16,"tag":152,"props":1610,"children":1611},{"style":169},[1612],{"type":21,"value":1474},{"type":16,"tag":152,"props":1614,"children":1615},{"style":235},[1616],{"type":21,"value":1617},"a' > /dev/tty\"",{"type":16,"tag":152,"props":1619,"children":1620},{"style":159},[1621],{"type":21,"value":1484},{"type":16,"tag":152,"props":1623,"children":1624},{"class":154,"line":203},[1625],{"type":16,"tag":152,"props":1626,"children":1627},{"style":159},[1628],{"type":21,"value":491},{"type":16,"tag":152,"props":1630,"children":1631},{"class":154,"line":216},[1632],{"type":16,"tag":152,"props":1633,"children":1634},{"style":159},[1635],{"type":21,"value":500},{"type":16,"tag":152,"props":1637,"children":1638},{"class":154,"line":319},[1639],{"type":16,"tag":152,"props":1640,"children":1641},{"style":159},[1642],{"type":21,"value":509},{"type":16,"tag":17,"props":1644,"children":1645},{},[1646,1648,1654,1656,1662],{"type":21,"value":1647},"With ",{"type":16,"tag":56,"props":1649,"children":1651},{"className":1650},[],[1652],{"type":21,"value":1653},"set -g monitor-bell on",{"type":21,"value":1655}," in your ",{"type":16,"tag":56,"props":1657,"children":1659},{"className":1658},[],[1660],{"type":21,"value":1661},"~/.tmux.conf",{"type":21,"value":1663},", the status bar highlights the window that needs you, which is more information than a pop-up saying \"Claude Code\". iTerm2 and most modern terminals can do the same through their own triggers or attention badges.",{"type":16,"tag":37,"props":1665,"children":1667},{"id":1666},"notify-only-when-it-was-actually-long",[1668],{"type":21,"value":1669},"Notify only when it was actually long",{"type":16,"tag":17,"props":1671,"children":1672},{},[1673,1675,1681,1683,1688],{"type":21,"value":1674},"Alerts you get every thirty seconds stop being alerts. If most of your turns are short, gate the notification on how long the turn took, by stamping the start in ",{"type":16,"tag":56,"props":1676,"children":1678},{"className":1677},[],[1679],{"type":21,"value":1680},"UserPromptSubmit",{"type":21,"value":1682}," and checking it in ",{"type":16,"tag":56,"props":1684,"children":1686},{"className":1685},[],[1687],{"type":21,"value":75},{"type":21,"value":1689},":",{"type":16,"tag":142,"props":1691,"children":1693},{"className":144,"code":1692,"language":146,"meta":7,"style":7},"{\n  \"hooks\": {\n    \"UserPromptSubmit\": [\n      { \"hooks\": [{ \"type\": \"command\", \"command\": \"date +%s > /tmp/claude-start\" }] }\n    ],\n    \"Stop\": [\n      { \"hooks\": [{ \"type\": \"command\", \"command\": \"[ $(( $(date +%s) - $(cat /tmp/claude-start) )) -gt 60 ] && notify-send 'Claude Code' 'Long run finished'\" }] }\n    ]\n  }\n}\n",[1694],{"type":16,"tag":56,"props":1695,"children":1696},{"__ignoreMap":7},[1697,1704,1715,1727,1775,1782,1793,1841,1848,1855],{"type":16,"tag":152,"props":1698,"children":1699},{"class":154,"line":155},[1700],{"type":16,"tag":152,"props":1701,"children":1702},{"style":159},[1703],{"type":21,"value":162},{"type":16,"tag":152,"props":1705,"children":1706},{"class":154,"line":165},[1707,1711],{"type":16,"tag":152,"props":1708,"children":1709},{"style":169},[1710],{"type":21,"value":172},{"type":16,"tag":152,"props":1712,"children":1713},{"style":159},[1714],{"type":21,"value":177},{"type":16,"tag":152,"props":1716,"children":1717},{"class":154,"line":180},[1718,1723],{"type":16,"tag":152,"props":1719,"children":1720},{"style":169},[1721],{"type":21,"value":1722},"    \"UserPromptSubmit\"",{"type":16,"tag":152,"props":1724,"children":1725},{"style":159},[1726],{"type":21,"value":191},{"type":16,"tag":152,"props":1728,"children":1729},{"class":154,"line":194},[1730,1734,1738,1742,1746,1750,1754,1758,1762,1766,1771],{"type":16,"tag":152,"props":1731,"children":1732},{"style":159},[1733],{"type":21,"value":1430},{"type":16,"tag":152,"props":1735,"children":1736},{"style":169},[1737],{"type":21,"value":1435},{"type":16,"tag":152,"props":1739,"children":1740},{"style":159},[1741],{"type":21,"value":1440},{"type":16,"tag":152,"props":1743,"children":1744},{"style":169},[1745],{"type":21,"value":227},{"type":16,"tag":152,"props":1747,"children":1748},{"style":159},[1749],{"type":21,"value":232},{"type":16,"tag":152,"props":1751,"children":1752},{"style":235},[1753],{"type":21,"value":238},{"type":16,"tag":152,"props":1755,"children":1756},{"style":159},[1757],{"type":21,"value":243},{"type":16,"tag":152,"props":1759,"children":1760},{"style":169},[1761],{"type":21,"value":238},{"type":16,"tag":152,"props":1763,"children":1764},{"style":159},[1765],{"type":21,"value":232},{"type":16,"tag":152,"props":1767,"children":1768},{"style":235},[1769],{"type":21,"value":1770},"\"date +%s > /tmp/claude-start\"",{"type":16,"tag":152,"props":1772,"children":1773},{"style":159},[1774],{"type":21,"value":1484},{"type":16,"tag":152,"props":1776,"children":1777},{"class":154,"line":203},[1778],{"type":16,"tag":152,"props":1779,"children":1780},{"style":159},[1781],{"type":21,"value":343},{"type":16,"tag":152,"props":1783,"children":1784},{"class":154,"line":216},[1785,1789],{"type":16,"tag":152,"props":1786,"children":1787},{"style":169},[1788],{"type":21,"value":352},{"type":16,"tag":152,"props":1790,"children":1791},{"style":159},[1792],{"type":21,"value":191},{"type":16,"tag":152,"props":1794,"children":1795},{"class":154,"line":319},[1796,1800,1804,1808,1812,1816,1820,1824,1828,1832,1837],{"type":16,"tag":152,"props":1797,"children":1798},{"style":159},[1799],{"type":21,"value":1430},{"type":16,"tag":152,"props":1801,"children":1802},{"style":169},[1803],{"type":21,"value":1435},{"type":16,"tag":152,"props":1805,"children":1806},{"style":159},[1807],{"type":21,"value":1440},{"type":16,"tag":152,"props":1809,"children":1810},{"style":169},[1811],{"type":21,"value":227},{"type":16,"tag":152,"props":1813,"children":1814},{"style":159},[1815],{"type":21,"value":232},{"type":16,"tag":152,"props":1817,"children":1818},{"style":235},[1819],{"type":21,"value":238},{"type":16,"tag":152,"props":1821,"children":1822},{"style":159},[1823],{"type":21,"value":243},{"type":16,"tag":152,"props":1825,"children":1826},{"style":169},[1827],{"type":21,"value":238},{"type":16,"tag":152,"props":1829,"children":1830},{"style":159},[1831],{"type":21,"value":232},{"type":16,"tag":152,"props":1833,"children":1834},{"style":235},[1835],{"type":21,"value":1836},"\"[ $(( $(date +%s) - $(cat /tmp/claude-start) )) -gt 60 ] && notify-send 'Claude Code' 'Long run finished'\"",{"type":16,"tag":152,"props":1838,"children":1839},{"style":159},[1840],{"type":21,"value":1484},{"type":16,"tag":152,"props":1842,"children":1843},{"class":154,"line":328},[1844],{"type":16,"tag":152,"props":1845,"children":1846},{"style":159},[1847],{"type":21,"value":491},{"type":16,"tag":152,"props":1849,"children":1850},{"class":154,"line":337},[1851],{"type":16,"tag":152,"props":1852,"children":1853},{"style":159},[1854],{"type":21,"value":500},{"type":16,"tag":152,"props":1856,"children":1857},{"class":154,"line":346},[1858],{"type":16,"tag":152,"props":1859,"children":1860},{"style":159},[1861],{"type":21,"value":509},{"type":16,"tag":17,"props":1863,"children":1864},{},[1865,1867,1872],{"type":21,"value":1866},"Keep the ",{"type":16,"tag":56,"props":1868,"children":1870},{"className":1869},[],[1871],{"type":21,"value":61},{"type":21,"value":1873}," hook ungated though: something blocking you is always worth interrupting for.",{"type":16,"tag":37,"props":1875,"children":1877},{"id":1876},"where-scripts-run-out-of-road",[1878],{"type":21,"value":1879},"Where scripts run out of road",{"type":16,"tag":17,"props":1881,"children":1882},{},[1883],{"type":21,"value":1884},"Notifications work well for one session. Run three or four at once and they start to blur together: which project just pinged? Was that a \"needs you\" or a \"done\"? Notification centres also collapse repeats, so a stack of five alerts becomes one line you have to expand. You are back to alt-tabbing to find out.",{"type":16,"tag":17,"props":1886,"children":1887},{},[1888,1890,1896,1898,1903],{"type":21,"value":1889},"That is the gap ",{"type":16,"tag":114,"props":1891,"children":1893},{"href":1892},"/",[1894],{"type":21,"value":1895},"Blooby",{"type":21,"value":1897}," fills. Instead of a notification per event, it gives ",{"type":16,"tag":52,"props":1899,"children":1900},{},[1901],{"type":21,"value":1902},"each",{"type":21,"value":1904}," Claude Code session its own animated mascot that reflects its state in real time, driven by these same hooks: it looks up when a session needs permission, celebrates when one finishes, dozes off when a session goes quiet. You glance at the corner of your screen and know which of your sessions wants you, with no config and no scripts to maintain.",{"type":16,"tag":1906,"props":1907,"children":1908},"style",{},[1909],{"type":21,"value":1910},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":7,"searchDepth":165,"depth":165,"links":1912},[1913,1914,1915,1916,1917,1918,1919,1920,1921],{"id":39,"depth":165,"text":42},{"id":124,"depth":165,"text":127},{"id":541,"depth":165,"text":544},{"id":798,"depth":165,"text":801},{"id":1024,"depth":165,"text":1027},{"id":1378,"depth":165,"text":1381},{"id":1521,"depth":165,"text":1524},{"id":1666,"depth":165,"text":1669},{"id":1876,"depth":165,"text":1879},"markdown","content:guides:claude-code-notifications.md","content","guides/claude-code-notifications.md","guides/claude-code-notifications","md",1]