shell-plugins
shell-plugins copied to clipboard
Using `cachix` with the Nix module produces trace warnings.
op CLI version
2.29.0, but this is related to the Nix Flake.
Nix Flake revision: d36189bf486ff2c4d9275c9ce29ec1aa92eaa4a7.
Goal or desired behavior
Enabling the Nix home-manager module, without any warnings for cachix.
Current behavior
When building my Home Manager configuration as a NixOS module, it produces a trace message when cachix is specified as a plugin.
Relevant log output
trace: warning: getExe: Package "cachix-1.7.4" does not have the meta.mainProgram
+attribute. We'll assume that the main program has the same name for now, but this behavior
+is deprecated, because it leads to surprising errors when the assumption does not hold. If
+the package has a main program, please set `meta.mainProgram` in its definition to make
+this warning go away. Otherwise, if the package does not have a main program, or if you
+don't control its definition, use getExe' to specify the name to the program, such as
+lib.getExe' foo "bar".
This is not a bug with this module, but more to do with a lack of a meta.mainProgram attribute set in certain upstream Nixpkgs derivations.
We could manually handle this with getExe' pkgs.cachix "cachix", but this would be an edge case.