my ubuntu setup uses 4 virtual desktops (1 high, 4 accross). As a programmer, I almost always open the same 4 windows in the same configuration, across my 4 virtual desktops:

| Firefox | Netbeans IDE | Firefox | Spotify |

I am hoping to come up with a single command that will launch each of these programs to their corresponding window. Pseudocode might look like:

open firefox on desktop 1 to gmail.com
open netbeans on desktop 2
open firefox on desktop 3 to localhost
open spotify on desktop 4

Does anyone know how I might create a simple script I could launch from my desktop to help me do this? Or at least a command parameter that causes a program to open to a specific desktop?



Do you use Compiz? Gnome Shell?

If you use Compiz, install "compizconfig-settings-manager":

sudo apt-get install compizconfig-settings-manager

Then open CompizConfig Settings Manager, enable the "Place Windows" plugin, then click it and on the "Fixed window placement" tab, under "Windows with fixed viewport" (the last option there), select "New". Here, select the workspace on which you want the application to open. Then click the "+" sign and then click "grab", then click the middle of the window for the application you want to run on a given desktop (workspace).

If you don't use Compiz, you can do this with an application called "devilspie". If you want a GUI for it, use "gdevilspie" (search for it in Ubuntu Software Center).

And finally, if you use Gnome Shell, see THIS.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.