Huu Phan | Blog Linux operating system | Linux operating system -Blog Huu Phan | www.huuphan.com

This Blog is protected by DMCA.com

huuphan.com. Powered by Blogger.

xdotool − command−line X11 automation tool

xdotool − command−line X11 automation tool
To install xdotool on ubuntu
sudo apt-get update
sudo apt-get install xdotool

To install xdotool on fedora
sudo yum install xdotool

To display the current coordinates of the mouse cusrsor on linux
#while true; do clear; xdotool getmouselocation; sleep 0.1; done
The simple script for xdotool

#!/bin/bash
xdotool mousemove 343 755 click 1
sleep 2
while true
do
    xdotool mousemove 392 44 click 1
    xdotool key "Return"
    sleep 3
    xdotool key Page_Up
    sleep 3
    xdotool mousemove 277 580 click 1
    sleep 3
    xdotool key Page_Down
    sleep 3
    xdotool mousemove 718 152 click 1
    sleep 3
    xdotool mousemove 46 482 click 1
    sleep 3
    xdotool mousemove 383 15 click 1
    sleep 3
done

Man xdotool
http://man.cx/xdotool

post new :

Huu Phan | Blog Linux operating system | Huu Phan ~ Zimbra Mail Server,linux,bash script,centos,linux command | www.huuphan.com