From b230995fcc1cafaf4c84bc09514105c57eef4a03 Mon Sep 17 00:00:00 2001 From: seth Date: Wed, 1 May 2024 17:38:50 -0400 Subject: [PATCH 1/2] pass nixpkgs directly in forAllSystems --- flake.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/flake.nix b/flake.nix index 7ad2a5c..574347b 100644 --- a/flake.nix +++ b/flake.nix @@ -13,7 +13,7 @@ "aarch64-linux" "x86_64-darwin" "aarch64-darwin" - ] (system: function system); + ] (system: function nixpkgs.legacyPackages.${system}); in { templates = { @@ -31,6 +31,6 @@ description = ""; }; }; - formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.nixfmt-rfc-style); + formatter = forAllSystems (pkgs: pkgs.nixfmt-rfc-style); }; } From 05b6628aa2b95a21b552f5355f86c0712baf7b66 Mon Sep 17 00:00:00 2001 From: seth Date: Wed, 1 May 2024 17:40:06 -0400 Subject: [PATCH 2/2] fix typos --- README.md | 4 ++-- darwin/core.nix | 2 +- darwin/flake.nix | 2 +- darwin/home.nix | 2 +- home-manager/flake.nix | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 55a0223..5ad7113 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ There are 3 main templates in this repository: #### With Darwin (macOS) -1. Run `nix flake new -t github:auxolotl/templates#darwin NixFiles` in the teminal. This will setup the basic configuration for the system, this generate a configuration for you from the files located in the `darwin` directory. +1. Run `nix flake new -t github:auxolotl/templates#darwin NixFiles` in the terminal. This will setup the basic configuration for the system, this generate a configuration for you from the files located in the `darwin` directory. 2. The next step is to go into the `NixFiles` directory this can be achieved by running `cd NixFiles`. 3. Now we you need to read over the configuration files and make any changes that you see fit, some of these must include changing your username and hostname. 4. You now must rebuild this configuration we can do this with `darwin-rebuild switch --flake .`. This assumes that your host name has not changed. @@ -30,4 +30,4 @@ Congratulations, you are now using Aux! 1. Run `nix flake new -t github:auxolotyl/templates#home-manager NixFiles` to start 2. Move into your new Nix system with `cd NixFiles` -3. Fill in your `username` in `flake.nix` \ No newline at end of file +3. Fill in your `username` in `flake.nix` diff --git a/darwin/core.nix b/darwin/core.nix index 1b8f7a0..5d187cb 100644 --- a/darwin/core.nix +++ b/darwin/core.nix @@ -13,7 +13,7 @@ # this allows the system builder to use substitutes builders-use-substitutes = true; - # we want these beacuse we don't have to build every package from source + # we want these because we don't have to build every package from source substituters = [ "https://nix-community.cachix.org" ]; trusted-public-keys = [ "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" ]; diff --git a/darwin/flake.nix b/darwin/flake.nix index a60370f..5e9fdca 100644 --- a/darwin/flake.nix +++ b/darwin/flake.nix @@ -11,7 +11,7 @@ # The `follows` keyword in inputs is used for inheritance. # we do this in order to prevent duplication of the nixpkgs input, and potential - # issues with diffrent versions of given packages. + # issues with different versions of given packages. # However, it should be noted that this can lead to having to rebuild packages from source. inputs.nixpkgs.follows = "nixpkgs"; }; diff --git a/darwin/home.nix b/darwin/home.nix index d623817..ea34399 100644 --- a/darwin/home.nix +++ b/darwin/home.nix @@ -3,7 +3,7 @@ # Home Manager needs a bit of information about you and the # paths it should manage. home = { - # rember we set this in our flake.nix file + # remember we set this in our flake.nix file username = username; homeDirectory = "/Users/${username}"; diff --git a/home-manager/flake.nix b/home-manager/flake.nix index e1a87fe..e5504f3 100644 --- a/home-manager/flake.nix +++ b/home-manager/flake.nix @@ -9,7 +9,7 @@ # The `follows` keyword in inputs is used for inheritance. # we do this in order to prevent duplication of the nixpkgs input, and potential - # issues with diffrent versions of given packages. + # issues with different versions of given packages. # However, it should be noted that this can lead to having to rebuild packages from source. inputs.nixpkgs.follows = "nixpkgs"; };