ydotool
ydotool copied to clipboard
manual/tutorial/help
Hi, I am experimenting with this tool to replace a xdotool based script. But it looks like it is segfaulting on my system which is the pre-released Ubuntu 2022.04.
ydotool is not running without ydotool, and the later is not quite good. I am seeing this seg fault quite often.
➜
[1] + 36279 segmentation fault sudo ydotoold
Now, I cannot do much, there is no manual, and not much info in the command line. I also could not find any tutorial, example, guide, or something explaining how to use it.
I cannot even get the version of the script. Generally the script has a command like -h that shows a brief info about it.
With the xdotool I am sending the commands to a specific window. Does ydotool have something similar?
I appreciate any help or pointer to a help. Thank you.
Hi there, I'm new to repo.
Have you had a look at the "manpages --> ydotool.1.scd" part of this repository yet? This file and the additional manpages found under "manpages" section can help you better understand ydotool (and it's deamon) along with requirements needed for them to run.
I am currently trying to get ydotoold to run as you are, but not fully operational just yet.
I tried to use it. It is segfaulting. It is not working. Since the name of the tool is a modified copy of xdotoolI am assuming it works the same way. But I was not able to use it since it segfaults as soon as I launch it.
See here... I am launching the daemon in the top window. And then when I run a command in the bottom windows, it crashes.

Now, running it without the daemon running, it looks like it is working. 19 days ago it was not working...

I have managed to get "ydotool" to work for me just a few hours ago, so I'll do my best to offer assistance.
Every time I had issues running "ydotool" or "ydotoold", they usually throw an error message (e.g. for my cases) "failed to connect socket" or "failed to find uinput". See example below:
Looking at your output and based on my experience, your output does not confirm whether your facing similar issues as I did or whether program is missing something else for it to operate. When I start ydotool, I do not get those messages like "accepted client" whereas you do, so I suspect your terminal or output is not capturing those errors for some reason...
Can you confirm /dev/uinput exist on your device? If not there, can you confirm if present in /dev/input/uinput?
Also, can you find out how to get error messages to be saved? Maybe this could help: https://askubuntu.com/questions/625224/how-to-redirect-stderr-to-a-file.
Hope this helps you.
0 crw-rw---- 1 root input 10, 223 Apr 19 21:26 /dev/uinput
➜ ~ groups
lheck adm dialout cdrom sudo dip plugdev input lpadmin lxd
Ah, I dropped ydotool since xdotool was working on wayland.
Ahh I see. Hmm... it would be interesting to see what error output you get when those errors occur. However, if xdotool is working for you through wayland (which means your probably using a hybrid x-server/Wayland system as I haven't heard of xdotool being supported by Wayland itself), then that is great to hear.
Ah, I dropped ydotool since xdotool was working on wayland.
xdotool is not supported in wayland. you're running on xwayland.
then that is it...
I just wrote a full tutorial on how to install and use ydotool on my website here: https://gabrielstaples.com/ydotool-tutorial/
Hopefully it helps some people.