-
-
Notifications
You must be signed in to change notification settings - Fork 145
Description
Hi,
when looking at e.g. nixpkgs.pkgs the defaultText uses a variable named "cfg". Within the packages declaring nix file it is more or less just an alias and also never gets redefined or anything.
So would it be possible to resolve such usages automatically and use their unaliased version?
https://github.com/NixOS/nixpkgs/blob/a672be65651c80d3f592a89b3945466584a22069/nixos/modules/misc/nixpkgs.nix#L9
https://github.com/NixOS/nixpkgs/blob/c97c47f2bac4fa59e2cbdeba289686ae615f8ed4/nixos/modules/misc/nixpkgs.nix#L119-L124
I fully understand that it would only work for very simple cases. However as this wasn't the first time I encountered such usages I at least wanted to ask if it'd be something worth considering to be added to the nixos search page even though it would only work for simple cases.
(In addition to this ticket I also opened a PR just now to change the defaultText of nixpkgs.pkgs to the unaliased version.)