#!/bin/bash ./Test.py & while true; do sleep 5m; if kill -0 %1; then kill -STOP %1; sleep 90; bg; else break; fi echo testtest LAYOUT="Top" WINFO=`xwininfo -root -tree -name "$LAYOUT Panel"| grep "pidgin" | cut -d ')' -f 2-` WIW=`echo $WINFO | cut -d 'x' -f 1` WIH=`echo $WINFO | cut -d 'x' -f 2 | cut -d '+' -f 1` WIX=`echo $WINFO | cut -d '+' -f 4` WIY=`echo $WINFO | cut -d '+' -f 5` let WAX=WIX+WIW/2 let WAY=WIY+WIH/2 dbus-send --type=method_call --dest=org.freedesktop.compiz /org/freedesktop/compiz/water/allscreens/point org.freedesktop.compiz.activate string:'root' int32:`xwininfo -root | grep id: | awk '{ print $4 }'` string:'amplitude' double:1 string:'x' int32:$WAX string:'y' int32:$WAY sleep 4 done