Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am looking for some form of utility that can be run from the command line in Ubuntu that will click a button in a specific window. What I want to do is run a macro in the selenium IDE without having to take my hands off the keyboard.

share|improve this question
add comment

1 Answer

up vote 5 down vote accepted

You can use the xdotool command line utility to create mouse (and keyboard) events.

It is quite versatile, so you probably need to look at the manual to find the commands for your particular purpose.

For example, to move the cursor to pixel position 500,500 and click, you would run

xdotool mousemove  500 500
xdotool click 1 # 1 is the left button.
share|improve this answer
    
Perfect Thank you! –  Zachary K Apr 11 '11 at 10:39
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.