aboutsummaryrefslogtreecommitdiffstats
path: root/flake.nix
diff options
context:
space:
mode:
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix40
1 files changed, 40 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix
new file mode 100644
index 0000000..44581ae
--- /dev/null
+++ b/flake.nix
@@ -0,0 +1,40 @@
+{
+ description = "Petri's system";
+ inputs = {
+ nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-23.11";
+ nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
+ home-manager = {
+ url = "github:nix-community/home-manager/release-23.11";
+ inputs.nixpkgs.follows = "nixpkgs";
+ };
+ };
+
+ outputs = inputs@{ self, nixpkgs, nixpkgs-unstable, home-manager, nixos-hardware, ... }:
+ let
+ inherit (self) outputs;
+ vars = {
+ user = "petri";
+ name = "Petri Hienonen";
+ email= "petri.hienonen@gmail.com";
+ location = "$HOME/.nix";
+ terminal = "alacritty";
+ editor = "helix";
+ shell = "fish";
+ };
+ in {
+ nixosConfigurations = {
+ saarni = nixpkgs.lib.nixosSystem {
+ system = "x86_64-linux";
+ specialArgs = {inherit inputs outputs vars nixpkgs-unstable; };
+ modules = [
+ ./hosts/saarni
+ {
+ home-manager.useGlobalPkgs = true;
+ home-manager.useUserPackages = true;
+ }
+ ];
+ };
+ };
+ };
+}
+