A tiny friend in your Mac's notch and on your iPhone that keeps an eye on your AI coding agents: Claude Code, Codex, Cursor, Gemini CLI, Antigravity and more. Approve from the notch or your Lock Screen.
Swift ai-agentsanthropicantigravityclaudeclaude-codecodexcursordynamic-islandgemini-cliiosiphonlinuxmacosmacos-appmenubar-appnotchopen-sourceswiftswiftuiwindows
Capture on ⌘⇧S, with a tick when the shortcut lands and each step in the log
Claudeb7e6c4b3aa3c
diff --git a/NotchBuddy/Sources/App/CaptureCardView.swift b/NotchBuddy/Sources/App/CaptureCardView.swiftindex 8a62676c..91563db6 100644--- a/NotchBuddy/Sources/App/CaptureCardView.swift+++ b/NotchBuddy/Sources/App/CaptureCardView.swift@@ -1,7 +1,7 @@#if !APPSTOREimport SwiftUI-/// The island after ⌃⌥X: Mochi on the left (he just swallowed the capture), the image, and what+/// The island after ⌘⇧S: Mochi on the left (he just swallowed the capture), the image, and what/// to do with it. With Flow on, holding its key sends the image and your words together.struct CaptureCardView: View {@ObservedObject private var capture = ScreenCapture.shareddiff --git a/NotchBuddy/Sources/App/FlowDictation.swift b/NotchBuddy/Sources/App/FlowDictation.swiftindex 518ad7dc..b169eb72 100644--- a/NotchBuddy/Sources/App/FlowDictation.swift+++ b/NotchBuddy/Sources/App/FlowDictation.swift@@ -363,7 +363,7 @@ final class FlowDictation: ObservableObject {let latest = self.current === listenif latest { self.current = nil }guard !text.isEmpty else { if latest { self.pill.rest() }; return }- // A capture waiting on the island (⌃⌥X): the image goes in first, then the words.+ // A capture waiting on the island (⌘⇧S): the image goes in first, then the words._ = await ScreenCapture.shared.pasteForDictation()let result = FlowPaste.insert(text)if latest { self.pill.rest() }diff --git a/NotchBuddy/Sources/App/HotKeyCenter.swift b/NotchBuddy/Sources/App/HotKeyCenter.swiftindex 2af7ee95..7ab41541 100644--- a/NotchBuddy/Sources/App/HotKeyCenter.swift+++ b/NotchBuddy/Sources/App/HotKeyCenter.swift@@ -143,6 +143,7 @@ final class HotKeyCenter {gHotKeyTable[idx] = action} else {conflicts.insert(action)+ appendAppLog("nb.log", "[Hotkey] \(action.rawValue) not registered (status \(status)): another app holds these keys")}}}diff --git a/NotchBuddy/Sources/App/IslandWindowController.swift b/NotchBuddy/Sources/App/IslandWindowController.swiftindex ed847441..88eb474a 100644--- a/NotchBuddy/Sources/App/IslandWindowController.swift+++ b/NotchBuddy/Sources/App/IslandWindowController.swift@@ -715,6 +715,7 @@ final class IslandWindowController: NSWindowController {case .captureScreen:#if !APPSTORE+ appendAppLog("nb.log", "[Capture] shortcut pressed")ScreenCapture.shared.begin()#endif}diff --git a/NotchBuddy/Sources/App/ScreenCapture.swift b/NotchBuddy/Sources/App/ScreenCapture.swiftindex 325d7ff6..d8c64703 100644--- a/NotchBuddy/Sources/App/ScreenCapture.swift+++ b/NotchBuddy/Sources/App/ScreenCapture.swift@@ -3,7 +3,7 @@ import AppKitimport Carbon.HIToolboximport SwiftUI-/// ⌃⌥X: capture a part of the screen (a bug in a page, an error, a mock-up), Mochi swallows it,+/// ⌘⇧S: capture a part of the screen (a bug in a page, an error, a mock-up), Mochi swallows it,/// and the island offers what to do with it: paste it into the prompt you were typing in, copy/// it, annotate it, or ask Claude about it in the island's chat.///@@ -35,8 +35,13 @@ final class ScreenCapture: ObservableObject {// MARK: - Capturingfunc begin() {- guard !running else { return }+ guard !running else {+ appendAppLog("nb.log", "[Capture] already selecting a zone")+ return+ }+ SoundEngine.shared.play("tick")guard CGPreflightScreenCaptureAccess() else {+ appendAppLog("nb.log", "[Capture] no Screen Recording permission: asking")// macOS asks once; then Coucou is to be allowed in Privacy → Screen Recording._ = CGRequestScreenCaptureAccess()AppState.shared.noteMessage = String(localized: "capture.permission")@@ -66,6 +71,7 @@ final class ScreenCapture: ObservableObject {do {running = truetry task.run()+ appendAppLog("nb.log", "[Capture] selection started")} catch {running = falseappendAppLog("nb.log", "[Capture] screencapture failed: \(error)")@@ -74,6 +80,7 @@ final class ScreenCapture: ObservableObject {private func finished(_ file: URL) {running = false+ appendAppLog("nb.log", "[Capture] selection ended, image: \(FileManager.default.fileExists(atPath: file.path) ? "yes" : "no (cancelled)")")// Esc: no file, nothing happens.guard FileManager.default.fileExists(atPath: file.path), let picture = NSImage(contentsOf: file) else { return }show(file, picture)diff --git a/NotchBuddy/Sources/App/ShortcutLogic.swift b/NotchBuddy/Sources/App/ShortcutLogic.swiftindex 2d3e29b8..13badaa3 100644--- a/NotchBuddy/Sources/App/ShortcutLogic.swift+++ b/NotchBuddy/Sources/App/ShortcutLogic.swift@@ -19,7 +19,7 @@ enum ShortcutAction: String, CaseIterable, Sendable {case desktopToggle = "desktopToggle" // ⌃⌥D — send Mochi to desktop / bring backcase wardrobeToggle = "wardrobeToggle" // ⌃⌥G — open / close wardrobecase talkToCoucou = "talkToCoucou" // (unset) — start listening without wake phrase (non-AppStore)- case captureScreen = "captureScreen" // ⌃⌥X — capture a part of the screen for Claude (non-AppStore)+ case captureScreen = "captureScreen" // ⌘⇧S — capture a part of the screen for Claude (non-AppStore)// MARK: UserDefaults keys@@ -109,7 +109,7 @@ enum ShortcutLogic {.desktopToggle: ShortcutSpec(keyCode: 2, nsFlags: ShortcutSpec.ctrlOpt), // ⌃⌥D.wardrobeToggle: ShortcutSpec(keyCode: 5, nsFlags: ShortcutSpec.ctrlOpt), // ⌃⌥G.talkToCoucou: ShortcutSpec(keyCode: 9, nsFlags: ShortcutSpec.ctrlOpt), // ⌃⌥V (disabled by default)- .captureScreen: ShortcutSpec(keyCode: 7, nsFlags: ShortcutSpec.ctrlOpt), // ⌃⌥X+ .captureScreen: ShortcutSpec(keyCode: 1, nsFlags: ShortcutSpec.cmdShift), // ⌘⇧S]// MARK: - Load / save (UserDefaults)diff --git a/docs/SPEC.md b/docs/SPEC.mdindex bdbd7978..70025fc4 100644--- a/docs/SPEC.md+++ b/docs/SPEC.md@@ -382,7 +382,7 @@ Ces raccourcis fonctionnent en arrière-plan sans permission Accessibilité.| Couper le son (`toggleMute`) | ⌃⌥M | `shortcut.toggleMute.keyCode` / `.flags` | Oui || Mochi sur le bureau (`toggleDesktopMochi`) | ⌃⌥D | `shortcut.toggleDesktopMochi.keyCode` / `.flags` | Oui || Ouvrir la garde-robe (`openWardrobe`) | ⌃⌥G | `shortcut.openWardrobe.keyCode` / `.flags` | Oui |-| Capture d'écran pour Claude (`captureScreen`) | ⌃⌥X | `shortcut.captureScreen.keyCode` / `.flags` | Oui (hors App Store) |+| Capture d'écran pour Claude (`captureScreen`) | ⌘⇧S | `shortcut.captureScreen.keyCode` / `.flags` | Oui (hors App Store) |- Si Carbon ne peut pas enregistrer un raccourci (conflit système), l'action est marquée `.conflict` dans `HotKeyCenter` et un indicateur apparaît dans Réglages → Raccourcis.- `toggleIsland` conserve les clés UserDefaults historiques (`hotkeyCode`, `hotkeyFlags`, `hotkeyEnabled`) pour ne pas casser les préférences existantes.@@ -435,7 +435,7 @@ Réglages → Raccourcis (`ShortcutsSettingsView`) :## 16. Capture d'écran pour Claude (build GitHub)-- ⌃⌥X : l'île se replie, puis la sélection de macOS (`screencapture -i -x -o`) : zone, Espace pour une fenêtre, Échap pour annuler. Première fois : permission Enregistrement de l'écran.+- ⌘⇧S : l'île se replie, puis la sélection de macOS (`screencapture -i -x -o`) : zone, Espace pour une fenêtre, Échap pour annuler. Première fois : permission Enregistrement de l'écran.- L'image arrive dans l'île (vue `.capture`) : son `gulp`, Mochi avale. Boutons : **Coller** (dans l'app où on était : ⌘V, ou ⌃V dans un terminal pour Claude Code ; le presse-papiers reprend son contenu après 1,5 s), **Copier**, **Annoter** (fenêtre : flèche, cadre, crayon, 4 couleurs, ⌘Z, l'image annotée revient dans l'île), **Demander à Claude** (chat de l'île, image jointe).- Avec Flow : tant que la capture est dans l'île (3 min max), maintenir la touche de dictée colle l'image puis les mots au relâchement.- Les captures restent dans le dossier temporaire (les 20 dernières) et ne partent vers Claude que si on les colle ou qu'on demande à Claude.