feat: use the same nixpkgs as much as possible - macOS

This commit is contained in:
Ryan Yin
2023-08-04 22:40:15 +08:00
parent 664506b6cb
commit e39b79c508
2 changed files with 11 additions and 1 deletions

View File

@@ -1,4 +1,5 @@
{
nixpkgs,
nix-darwin,
home-manager,
system,
@@ -13,6 +14,15 @@ in
modules =
darwin-modules
++ [
{
# make `nix run nixpkgs#nixpkgs` use the same nixpkgs as the one used by this flake.
nix.registry.nixpkgs.flake = nixpkgs;
# make `nix repl '<nixpkgs>'` use the same nixpkgs as the one used by this flake.
environment.etc."nix/inputs/nixpkgs".source = "${nixpkgs}";
nix.nixPath = ["/etc/nix/inputs"];
}
home-manager.darwinModules.home-manager
{
home-manager.useGlobalPkgs = true;