Created
March 4, 2018 12:56
-
-
Save aerosol/606169e60e40b85d1e8c84ef40b9d670 to your computer and use it in GitHub Desktop.
linux desktop tyranny
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
W=`xdotool getactivewindow` | |
S1=`xprop -id ${W} |awk -F '"' '/WM_CLASS/{print $4}'` | |
echo "$S1" >> /tmp/log.txt | |
if [ "$S1" = "Firefox" ]; then | |
xdotool keydown --window ${W} Ctrl+t | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment