Created
October 26, 2022 15:35
-
-
Save svandragt/d731081c660d374ddab846e7f4c07198 to your computer and use it in GitHub Desktop.
Hide others for elementary / ubuntu.
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 | |
# hideothers.sh | |
active_window_id=$(xdotool getactivewindow) | |
for window_id in $(xdotool search --onlyvisible ".*") | |
do | |
if [ $window_id != $active_window_id ] | |
then | |
wname=$(xdotool getwindowname $window_id) | |
if [ "$wname" != "" ] && [ "$wname" != "plank" ] && [ "$wname" != "io.elementary.wingpanel" ] | |
then | |
echo $wname | |
xdotool windowminimize $window_id | |
fi | |
fi | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment