MacOS – Assign an agent app to all desktops

desktopdockmacos

I am running an app (Simple Floating Clock) that runs as an agent (LSUIElement assigned to 1 in the app's Info.plist).

I would like to assign the app to "All Desktops" that I run. Normally, if an app is not an agent, I can right click on the dock icon, select options, and then click "All Desktops".

Is there a simple way to set the all desktops behavior, maybe using the command line or something?

Best Answer

Assign the app to All Desktops, then set LSUIElement to 1. It should remember the change and abide by it even though it now runs as an agent.