diff --git a/nixos/configuration.nix b/nixos/configuration.nix index a087d8b..fd809c0 100644 --- a/nixos/configuration.nix +++ b/nixos/configuration.nix @@ -10,6 +10,9 @@ ./hardware-configuration.nix ]; + # Enable Flakes and the new command-line tool + nix.settings.experimental-features = [ "nix-command" "flakes" ]; + # Bootloader. boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; diff --git a/nixos/flake.nix b/nixos/flake.nix new file mode 100644 index 0000000..a09f2e0 --- /dev/null +++ b/nixos/flake.nix @@ -0,0 +1,29 @@ +{ + description = "aleidk NixOs Flake"; + + # Inputs + # https://nixos.org/manual/nix/unstable/command-ref/new-cli/nix3-flake.html#flake-inputs + + # Add more sources + # https://nixos-and-flakes.thiscute.world/nixos-with-flakes/nixos-with-flakes-enabled#managing-system-packages-with-flakes + + inputs = { + nixpkgs.url = "nixpkgs"; + home-manager = { + url = "github:nix-community/home-manager/release-23.05"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + }; + + outputs = { self, nixpkgs, ... }@inputs: { + nixosConfigurations = { + "nixos" = nixpkgs.lib.nixosSystem { + system = "x86_64-linux"; + modules = [ + ./configuration.nix + ]; + }; + }; + + }; +}