2022-09-17 16:50:50 +02:00
|
|
|
# My first run with nix. The config is based on Matthias Benaets config and youtube tutorial
|
|
|
|
# https://github.com/MatthiasBenaets/nixos-config
|
|
|
|
# https://www.youtube.com/watch?v=AGVXJ-TIv3Y
|
|
|
|
#
|
|
|
|
# flake.nix *
|
|
|
|
# ├─ ./hosts
|
|
|
|
# │ └─ default.nix
|
|
|
|
|
2022-09-16 22:44:43 +02:00
|
|
|
{
|
2022-09-17 16:50:50 +02:00
|
|
|
description = "Kabbone's peronal NixOS Flake config";
|
2022-09-16 22:44:43 +02:00
|
|
|
|
|
|
|
inputs = {
|
2022-09-17 16:50:50 +02:00
|
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; # Nix Packages
|
|
|
|
|
|
|
|
home-manager = { # User Package Management
|
2022-09-16 22:44:43 +02:00
|
|
|
url = github:nix-community/home-manager;
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
|
|
|
|
2022-09-17 16:50:50 +02:00
|
|
|
nur = {
|
|
|
|
url = "github:nix-community/NUR"; # NUR Packages
|
|
|
|
};
|
2022-09-16 22:44:43 +02:00
|
|
|
|
2022-09-17 16:50:50 +02:00
|
|
|
hyprland = { # Official Hyprland flake
|
|
|
|
url = "github:vaxerski/Hyprland";
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
2022-09-16 22:44:43 +02:00
|
|
|
};
|
2022-09-17 16:50:50 +02:00
|
|
|
|
|
|
|
outputs = { self, nixpkgs, home-manager, nur, hyperland, ... }:
|
|
|
|
let Variables that can be used in the config files
|
|
|
|
user = "kabbone";
|
|
|
|
location = "$HOME/.setup";
|
|
|
|
in # Use above variables in ...
|
|
|
|
{
|
|
|
|
nixosConfigurations = ( # NixOS configuration
|
|
|
|
import ./hosts { # Imports ./hosts/default.nix
|
|
|
|
inherit (nixpkgs) lib;
|
|
|
|
inherit inputs nixpkgs home-manager nur user location hyprland; # Also inherit home-manager so it does not need to be defined here.
|
|
|
|
}
|
|
|
|
);
|
|
|
|
};
|
2022-09-16 22:44:43 +02:00
|
|
|
}
|