add flake

This commit is contained in:
tristan 2023-04-08 15:35:17 +01:00
parent a62078bbf2
commit 1a500b92dc
2 changed files with 35 additions and 1 deletions

32
flake.nix Normal file
View file

@ -0,0 +1,32 @@
{
description = "A flake using my config";
inputs = {
nixpkgs.url = "nixpkgs/nixos-22.11";
home-manager.url = "github:nix-community/home-manager/release-22.11";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = { nixpkgs, home-manager, ... }:
let
system = "x86_64-linux";
pkgs = import nixpkgs {
inherit system;
};
lib = nixpkgs.lib;
in {
nixosConfigurations = {
nixbookpro = lib.nixosSystem {
inherit system;
modules = [
./system/configuration.nix
];
};
};
};
}

View file

@ -19,10 +19,12 @@ in {
];
nix.settings = {
experimental-features = [ "nix-command" ];
experimental-features = [ "nix-command" "flakes" ];
substituters = ["https://hyprland.cachix.org"];
trusted-public-keys = ["hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="];
};
nix.settings.trusted-users = [ "root" "tristan" ];
# Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot.enable = true;