Celeb Glow
updates | March 26, 2026

Launch multiple programs in different workspaces

I'm trying to make an startup script which launches several programs in a new gnome workspace using wmctrl. However, the script is not working as intended. The windows do not move until the script is run again.

#!/bin/bash
firefox &
gnome-system-monitor &
gnome-control-center network &
while [[ $(wmctrl -l | wc -l) -lt 3 ]]; do sleep 1 date
done
wmctrl -r Mozilla Firefox -t 1
wmctrl -r System Monitor -t 2
wmctrl -r Settings -t 3
3 Reset to default

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy