ydotool icon indicating copy to clipboard operation
ydotool copied to clipboard

manual/tutorial/help

Open leoheck opened this issue 3 years ago • 11 comments
trafficstars

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.

leoheck avatar Apr 02 '22 00:04 leoheck

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.

bobbybrot avatar Apr 20 '22 07:04 bobbybrot

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.

leoheck avatar Apr 20 '22 14:04 leoheck

See here... I am launching the daemon in the top window. And then when I run a command in the bottom windows, it crashes.

image

leoheck avatar Apr 20 '22 14:04 leoheck

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

leoheck avatar Apr 20 '22 14:04 leoheck

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:

image

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.

bobbybrot avatar Apr 20 '22 14:04 bobbybrot

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

leoheck avatar Apr 20 '22 14:04 leoheck

Ah, I dropped ydotool since xdotool was working on wayland.

leoheck avatar Apr 20 '22 14:04 leoheck

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.

bobbybrot avatar Apr 20 '22 14:04 bobbybrot

Ah, I dropped ydotool since xdotool was working on wayland.

xdotool is not supported in wayland. you're running on xwayland.

dhan78 avatar May 03 '22 20:05 dhan78

then that is it...

leoheck avatar May 04 '22 00:05 leoheck

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.

ElectricRCAircraftGuy avatar Jun 18 '23 03:06 ElectricRCAircraftGuy