-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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/espanso: add wayland and package option #285138
Conversation
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/3370 |
We cannot compile x11 and wayland at the same time? :( |
wayland = mkOption { | ||
type = types.bool; | ||
default = false; | ||
description = lib.mdDoc "Use the Wayland build of Espanso."; | ||
}; |
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.
It would probably cleaner to add the wayland variant to the related options of the package option
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.
So create a services.espanso.package.wayland
option?
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.
It would probably cleaner to add the wayland variant to the related options of the package option
@SuperSandro2000 could you explain exactly what you meant here?
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.
Is there a reason to use a second variable (cfg.wayland
) as opposed to having users specify package = pkgs.espanso-wayland
? It seems like the latter is more common and a little less complex.
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 @n8henrie said
mkPackageOption takes a related packages argument and we can write that there
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 wanted to have a wayland option so it would be a bit more discoverable for users when enabling espanso, but a package option with the example set is good enough.
Unfortunately does not seem possible with espanso atm. |
f6611cb
to
52da022
Compare
a1a8350
to
f6e3884
Compare
dropped the mainProgram commit, looks like it got merged already |
}; | ||
|
||
config = mkIf cfg.enable { | ||
services.espanso.package = mkIf cfg.wayland pkgs.espanso-wayland; |
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.
the wayland
option does not exist
enabling the espanso service prevents building NixOS
This option is unused in the module. As discussed in NixOS#317457 and NixOS#285138 (comment) users should just set the `package` option.
This option is unused in the module. As discussed in #317457 and #285138 (comment) users should just set the `package` option. (cherry picked from commit 526239b)
This adds two options to the espanso module. One that enables wayland support by using the espanso-wayland package, and a package option.
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.