docs: README — non-root ydotoold setup (systemd user service + input-group udev rule)#315
Open
SMC17 wants to merge 1 commit into
Open
docs: README — non-root ydotoold setup (systemd user service + input-group udev rule)#315SMC17 wants to merge 1 commit into
SMC17 wants to merge 1 commit into
Conversation
Documents the systemd-user + input-group + udev-rule pattern that multiple open issues (ReimuNotMoe#42, ReimuNotMoe#73, ReimuNotMoe#207, ReimuNotMoe#210) have asked for. The README currently states 'this usually requires root permissions', which leads users to assemble the non-root setup from external blog posts and frequently get it wrong. The pattern shipped here is the minimal working configuration: - input group membership for /dev/uinput access - udev rule with KERNEL=="uinput" + GROUP="input" + MODE="0660" - modprobe + static_node uinput so the rule applies on load - systemd --user enable ydotoold.service (built by default) - YDOTOOL_SOCKET pointing at $XDG_RUNTIME_DIR/.ydotool_socket Tested on Arch Linux 6.x + Hyprland (Wayland). Pure docs change; no code touched.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The current README says "
ydotoold(daemon) program requires access to/dev/uinput. This usually requires root permissions." — which leads users to assemble the non-root setup from external blog posts and frequently get it wrong. Several open issues document this exact pain (#42, #73, #207, #210).This PR adds a short "Running ydotoold without root (recommended setup)" subsection right after the existing Runtime note. The pattern shipped here is the minimal working configuration verified on Arch Linux 6.x + Hyprland (Wayland):
usermod -aG input "$USER"— input group for /dev/uinput access/etc/udev/rules.d/60-uinput.rules—KERNEL=="uinput", GROUP="input", MODE="0660", OPTIONS+="static_node=uinput"udevadm control --reload-rules+modprobe -r uinput && modprobe uinputso the static_node option applies on this loadsystemctl --user enable --now ydotoold.service(built by default whenSYSTEMD_USER_SERVICE=ON)export YDOTOOL_SOCKET="$XDG_RUNTIME_DIR/.ydotool_socket"— the user service writes the socket under$XDG_RUNTIME_DIR, not/tmpPure docs change; no code touched. The diff is +49 / -0 on README.md only.
Why it matters
The recurring question pattern in the issue tracker is the same: "I built ydotool, the daemon won't start as my user, I added the udev rule, it still doesn't work." Almost always the missing step is either step 3 (the rule doesn't apply until the module is reloaded) or step 5 (the socket path under
$XDG_RUNTIME_DIRrather than/tmp). Documenting both inline avoids the cycle.Does not close any issues automatically, but addresses the recurring question pattern in:
ydotool#207 (tutorial request)udevrule tog+rwthe/dev/uinputdoes not work #210 (udev rule not working)Happy to revise if the maintainer prefers a different framing or location in the README.