New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nixos/ydotool: module init #191911
base: master
Are you sure you want to change the base?
nixos/ydotool: module init #191911
Conversation
Sorry i didn't check existing PR;s before but found #107210 just now. |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/prs-ready-for-review/3032/1724 |
7a768f3
to
cfe2831
Compare
Removed the wrapping of the binaries with |
3413f38
to
95733fa
Compare
@@ -26,6 +26,8 @@ In addition to numerous new and upgraded packages, this release has the followin | |||
|
|||
- [fzf](https://github.com/junegunn/fzf), a command line fuzzyfinder. Available as [programs.fzf](#opt-programs.fzf.fuzzyCompletion). | |||
|
|||
- [ydotool](https://github.com/ReimuNotMoe/ydotool), Generic command-line automation tool. Available as [programs.ydotool](#opt-programs.ydotool.enable). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does Generic command-line automation tool
mean?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've taken the description from upstream. I think what they're trying to convey is that it works under wayland, xorg, fbdev, ..
I can of course change it if it's not adequate
nixos/modules/programs/ydotool.nix
Outdated
|
||
systemd.user.services.ydotoold = { | ||
description = "Starts ydotoold service"; | ||
wantedBy = [ "defaul.target" ]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be multi-user.target
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From what i've gathered it should be default.target
for user services?
edit: i fixed the typo in the meantime
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
default.target
should be correct, multi-user.target
is only for system services.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually it hit me just now that this depends on my user being in the group input
. Maybe this should be changed to a system wide service and be ran as root instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As the ydotool client uses XDG_RUNTIME_DIR
i didn't change it back to a system service, but added documentation about the user needing to be in the input
group.
aa07634
to
e0f8aaa
Compare
e0f8aaa
to
a6a1683
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! I've tried it in a VM and it works well!
In addition to adding the options we discussed offline, I only have two very minor nitpicks: as it's technically a service, it should be in the services
options category and the service description should be a short description of the program it's running.
{ | ||
|
||
options = { | ||
programs.ydotool = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
programs.ydotool = { | |
services.ydotool = { |
@@ -34,6 +34,8 @@ In addition to numerous new and upgraded packages, this release has the followin | |||
|
|||
- [fzf](https://github.com/junegunn/fzf), a command line fuzzyfinder. Available as [programs.fzf](#opt-programs.fzf.fuzzyCompletion). | |||
|
|||
- [ydotool](https://github.com/ReimuNotMoe/ydotool), Generic command-line automation tool. Available as [programs.ydotool](#opt-programs.ydotool.enable). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- [ydotool](https://github.com/ReimuNotMoe/ydotool), Generic command-line automation tool. Available as [programs.ydotool](#opt-programs.ydotool.enable). | |
- [ydotool](https://github.com/ReimuNotMoe/ydotool), Generic command-line automation tool. Available as [services.ydotool](#opt-services.ydotool.enable). |
environment.systemPackages = [ pkgs.ydotool ]; | ||
|
||
systemd.user.services.ydotoold = { | ||
description = "Starts ydotoold service"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
description = "Starts ydotoold service"; | |
description = "Daemon for ydotool"; |
For this to work, I had to add |
Description of changes
Resolves #183659
As
ydotool
supports text consoles i putwantedBy
="default.target"
instead of"graphical-session.target"
I don't think this is realated but
nixpkgs-review
fails:nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD
nixos-install-tools is blacklisted in nixpkgs-review
Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)nixos/doc/manual/md-to-db.sh
to update generated release notes