Bonus: vsplit to another file. ;)
I have 9 workspaces, and often have multiple terminals running VIM on different files. The setup is pretty standard for a project—but I have to go about opening five terminals, moving each to its own workspace, maximizing, opening a .hpp file in VIM and vsplitting its corresponding .cpp file for each terminal.
I'd like to write a script for this, but am at a loss as to how! Searching Google and testing on gedit, I began with something like
wmctrl -s 4 ; gedit & sleep 3; wmctrl -s 0;
But this only opens up gedit in the workspace I'm currently on. One potential issue (but I'm ignorant enough about this to not know whether or not it's actually a problem) is that I use the Compiz wallpaper feature that allows different wallpapers on different workspaces.
Ideally, I would like to work towards a script that does this for me and not a plugin.
Any hints or ideas?
wmctrl
. What I've noticed with Unity just now is thatwmctrl -d
reports just one desktop even though i have multiple workspaces enabled. That might be an issue.&&
.