refactor: overhaul flake - #37
Conversation
|
Thanks for this, it's a solid cleanup and the split into One change needed before merge:
forEachSystem =
perSystem:
lib.genAttrs [ "x86_64-linux" "aarch64-linux" ] (
system: perSystem nixpkgs.legacyPackages.${system} system
);One small correction to the PR description, no code change needed: Optional, entirely up to you since you're already in that file: adding Everything else I spotted is minor polish ( |
- Split package, NixOS module, and devshell into their own files - Drop flake-utils in favor of a small helper - Extract version from pyproject.toml instead of hardcoding - Add package option to NixOS module - Use environment.etc for polkit configuration - Use inputsFrom in devshell to avoid duplicating build inputs - Translate option descriptions to English - Switch nixpkgs input to channel tarball URL
Ah I didn't test with
Thanks for the correction, my bad, I assumed it was a string. Updated the PR description for future reference.
I did consider that but decided against it, as it seems to me like |
|
Thanks for the quick turnaround, the explicit system list and the On polkit. I'd rather not flip the default. I think The concrete problem with the current state is that without config = lib.mkIf cfg.enable {
security.polkit.enable = lib.mkDefault cfg.enablePolkit;
...
};If you'd still rather not touch warnings = lib.optional (cfg.enablePolkit && !config.security.polkit.enable)
"programs.monique.enablePolkit is set but security.polkit.enable is false, so the rule will have no effect.";Either is fine by me. Silence is the one option I'd like to avoid. Two more things before merge, both small.
Nit, no action needed if you'd rather I do it: the The rest of my earlier list ( |
|
Thanks for the follow-up.
Fair point, went with your suggestion:
Changed to plain
Added
Updated both to include Niri. |
|
Thanks for the thorough back and forth on this, and for picking up the The split into Merging. The remaining polish stays with me as agreed: |
This PR overhauls the flake to be more maintainable and follow current best practices.
pyproject.tomlat build time instead of being hardcodedenvironment.etcfor controllable ordering and to avoid interference with10-nixos.rulesTested nix run, nix develop, as well as using the NixOS module in my own config.