nix-community / nix-on-droid

Nix-enabled environment for your Android device. [maintainers=@t184256,@Gerschtli]
https://nix-on-droid.unboiled.info
MIT License
1.15k stars 65 forks source link

home-manager: Extend `lib` instead of `pkgs.lib` #316

Closed azuwis closed 3 months ago

azuwis commented 6 months ago

This will allow extending lib using:

_modules.args.lib = ...

Without this the extended lib is not available to home-manager modules.

I'm using _module.args.lib to extend the lib, add lib.my functions to all system modules and home-manager modules, it works in both NixOS and nix-darwin, but not in nix-on-droid.

This is also how home-manager nixos and nix-darwin module works.

azuwis commented 3 months ago

Merged in https://github.com/nix-community/nix-on-droid/pull/336