From bbb1c76500baeec9068f197fe6b068895a4fb0ce Mon Sep 17 00:00:00 2001 From: Kat Huang Date: Tue, 13 Aug 2024 21:32:27 -0600 Subject: [PATCH] [nix-darwin] Updates --- nix-darwin/flake.lock | 23 ++++++++++++++++++++++- nix-darwin/flake.nix | 26 +++++++++++++++++--------- 2 files changed, 39 insertions(+), 10 deletions(-) diff --git a/nix-darwin/flake.lock b/nix-darwin/flake.lock index 2551a964..8f9d8f97 100644 --- a/nix-darwin/flake.lock +++ b/nix-darwin/flake.lock @@ -3,7 +3,7 @@ "agenix": { "inputs": { "darwin": "darwin", - "home-manager": "home-manager", + "home-manager": "home-manager_2", "nixpkgs": [ "railbird-secrets", "nixpkgs" @@ -101,6 +101,26 @@ } }, "home-manager": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1723399884, + "narHash": "sha256-97wn0ihhGqfMb8WcUgzzkM/TuAxce2Gd20A8oiruju4=", + "owner": "nix-community", + "repo": "home-manager", + "rev": "086f619dd991a4d355c07837448244029fc2d9ab", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "home-manager", + "type": "github" + } + }, + "home-manager_2": { "inputs": { "nixpkgs": [ "railbird-secrets", @@ -296,6 +316,7 @@ }, "root": { "inputs": { + "home-manager": "home-manager", "homebrew-cask": "homebrew-cask", "homebrew-core": "homebrew-core", "nix-darwin": "nix-darwin", diff --git a/nix-darwin/flake.nix b/nix-darwin/flake.nix index b33e77da..6637eacf 100644 --- a/nix-darwin/flake.nix +++ b/nix-darwin/flake.nix @@ -19,22 +19,26 @@ url = "github:homebrew/homebrew-cask"; flake = false; }; - + home-manager.url = "github:nix-community/home-manager"; + home-manager.inputs.nixpkgs.follows = "nixpkgs"; }; - outputs = inputs@{ self, nix-darwin, nixpkgs, ... }: + outputs = inputs@{ self, nix-darwin, nixpkgs, home-manager, ... }: let configuration = { pkgs, config, ... }: { environment.systemPackages = with pkgs; [ emacs - slack - gitFull - ripgrep - yarn - nodePackages.prettier - vim - just + alejandra cocoapods + gitFull + just + nodePackages.prettier + nodejs + ripgrep + slack + typescript + vim + yarn ]; nixpkgs.config.allowUnfree = true; @@ -62,6 +66,9 @@ # The platform the configuration will be used on. nixpkgs.hostPlatform = "aarch64-darwin"; users.users.kat.openssh.authorizedKeys.keys = inputs.railbird-secrets.keys.kanivanKeys; + + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; }; in { @@ -69,6 +76,7 @@ # $ darwin-rebuild build --flake .#Kats-Mac-mini darwinConfigurations."Kats-Mac-mini" = nix-darwin.lib.darwinSystem { modules = [ + home-manager.darwinModules.home-manager configuration ]; };