feat: desktop notification when goose finishes a task (#8647)

Signed-off-by: Abhijay Jain <Abhijay007j@gmail.com>
This commit is contained in:
Abhijay Jain
2026-04-22 23:26:49 +05:30
committed by GitHub
parent 15cfd127ca
commit ee46794b18
6 changed files with 112 additions and 33 deletions
+13 -5
View File
@@ -749,11 +749,14 @@ const createChat = async (app: App, options: CreateChatOptions = {}) => {
// Nudge the user if mesh is their provider but isn't running.
// Delay to let the renderer mount before sending the IPC event.
setTimeout(() => {
mesh.checkProviderRunning(goosedClient).then((ok) => {
if (!ok && !mainWindow.isDestroyed()) {
mainWindow.webContents.send('mesh-not-running');
}
}).catch(() => {});
mesh
.checkProviderRunning(goosedClient)
.then((ok) => {
if (!ok && !mainWindow.isDestroyed()) {
mainWindow.webContents.send('mesh-not-running');
}
})
.catch(() => {});
}, 5000);
// Let windowStateKeeper manage the window
@@ -1359,6 +1362,7 @@ const validSettingKeys: Set<string> = new Set([
'showMenuBarIcon',
'showDockIcon',
'enableWakelock',
'enableNotifications',
'spellcheckEnabled',
'externalGoosed',
'globalShortcut',
@@ -1572,6 +1576,10 @@ ipcMain.handle('get-spellcheck-state', () => {
}
});
ipcMain.handle('is-any-window-focused', () => {
return BrowserWindow.getFocusedWindow() !== null;
});
// Add file/directory selection handler
ipcMain.handle('select-file-or-directory', async (_event, defaultPath?: string) => {
const dialogOptions: OpenDialogOptions = {