export default async ({ $ }) => { const notify = (summary, body) => { $`notify-send -a opencode ${summary} ${body}`.quiet().nothrow().catch(() => {}) } return { event: async ({ event }) => { if (event.type === "permission.asked") { notify("opencode needs input", event.properties.title ?? event.properties.type) } else if (event.type === "session.idle") { notify("opencode finished", "Agent is idle") } }, } }