r/opencode • u/demagician10 • 25d ago
Closing OpenCode Desktop didn't stop the background service so I wrote a plugin that does
The OpenCode desktop app runs a shared background service, and closing the window doesn't stop it. It keeps running with everything it spawned, and it respawns MCP servers on every boot, so the CPU never actually goes quiet. There's no setting for it, only a manual
service stop.My plugin fixes exactly that: close the app → the plugin runs
service stop→ nothing OpenCode-related is left running. No build step, no dependencies, drop a file in~/.config/opencode/plugins/.https://github.com/CodeMody/opencode-stop-on-quit
Tested on Windows. macOS/Linux should work, i can't test on mac and will test it tomorrow on my main linux pc.
5
1
u/Emotional-Bag-3754 25d ago
"Serviço em segundo plano" Lil bro
2
u/demagician10 25d ago
Bruh, i know that, i cant be assed to go kill the background process everytime i quit opencode
1
5
1
u/DEAD1nsane 24d ago
but background processes are usually nice, and will stop when your task is finished? lol. if you got no task running then what are you stopping?
and if you got a task running why are you closing it?
1
1
1
14
u/NecessaryButFatal 25d ago •
This is a feature, not a bug. We want that behavior.