I'm running
fvwm
and have multiple virtual desktops open. I'd like to be able to write a bash script that would take me from one xterm to another---this part is easy, using wmctrl -a
---and then back again, which is the hard part.
I imagine that if I could execute a command in the new window once I've passed control to it, then the rest would be easy, but as far as I can tell from the documentation, wmctrl doesn't give me the option to do this.
Here's the basic idea of the script I'd like to write
#!/bin/bash
TmpScreen=CAMILLE
CurrScreen=ANDREW
wmctrl -R $TmpScreen
#echo this line on CAMILLE not ANDREW
echo "Type 'GoBack' to return to $CurrScreen" &
#Do something on CAMILLE
#Type GoBack, which would then execute
wmctrl -a $CurrScreen
#Be back to where I started
Is there a way to accomplish this? Any help would be most appreciated
Asked by Leo Simon
(453 rep)
Feb 7, 2018, 07:00 PM