From dc06d29cf1deee84104029d9d8e017b8d664f59d Mon Sep 17 00:00:00 2001 From: greyweather Date: Sun, 6 Sep 2026 02:21:32 +0100 Subject: [PATCH] Update README.md --- README.md | 44 ++++++-------------------------------------- 1 file changed, 6 insertions(+), 38 deletions(-) diff --git a/README.md b/README.md index eca6460..89e122b 100644 --- a/README.md +++ b/README.md @@ -1,40 +1,8 @@ -### installation -first, you must edit /etc/nixos/configuration.nix to include the following: -``` -{ - config, - pkgs, - ... -}: { - imports = [ - <...> - ]; +### How to use +My recommendation would be to clone this repo, make a copy of it, delete the contents of `modules/hosts/` in your copy, and create your own host modules from scratch using mine as a reference for how they are constructed. +The directory structure (i.e. the location of the actual files) within the `modules/` directory does not matter, since all `*.nix` files contained anywhere below `modules/` are automatically found, imported and merged. - nix.settings.experimental-features = [ - "nix-command" - "flakes" - ]; +Make sure to check the default values for options, since for example the default `info.userName` value is `"grey"`, which will cause things to break if it is not set to match your own username. +Adding the line `features.documentation.enable = true;` to your host config will build a static website that runs on http://localhost:8080, which describes all of the options I have created for this flake. For general NixOS / Home Manager options, I recommend [NixOS Search](https://search.nixos.org/options). - <...> - - networking.hostname = ""; - - <...> - - environment.systemPackages = with pkgs; [ - git - ]; -} -``` - -then, run `sudo nixos-rebuild switch` once to apply those changes. - -reboot, to make sure that everything applied properly. - -make sure to `cp /etc/nixos/hardware-configuration ~/nixos/hosts/` to apply the generated hardware config for your system - -finally, run `sudo nixos-rebuild switch --flake /home/grey/nixos#` to apply the flake. - -reboot again, and you should now land on your desktop/login screen! - -now you have access to `nh os switch ~/nixos`, and shouldn't touch the global config ever again. +The `modules/global/` directory is probably also something to be aware of, since this is for config that is considered global (applied to all hosts) *for me*, and will not necessarily apply to you. \ No newline at end of file