James's Ramblings

wmctrl

Created: March 11, 2020

Move active window to a new empty workspace

wmctrl -r :ACTIVE: -t `wmctrl -d | tail -n 1 | cut -d" " -f1

Move active window to the next workspace (without following the window)

wmctrl -r :ACTIVE: -t $((`wmctrl -d | egrep "\*" | head -n 1 | cut -d" " -f1`+1))
wmctrl -r :ACTIVE: -e 0,-10,25,800,500