Archived
0
0
Fork 0
This repository has been archived on 2024-02-06. You can view files and clone it, but cannot push or open issues or pull requests.
flake/flake.nix

107 lines
2.6 KiB
Nix
Raw Normal View History

2022-12-21 06:27:41 +00:00
{
2023-01-02 07:09:38 +00:00
description = "The nix flake for all my systems";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
2022-12-21 06:27:41 +00:00
2023-01-02 07:09:38 +00:00
neovim.url = "github:neovim/neovim?dir=contrib";
neovim.inputs.nixpkgs.follows = "nixpkgs";
neovim.inputs.flake-utils.follows = "utils";
2022-12-28 08:22:43 +00:00
2023-01-02 07:09:38 +00:00
home-manager.url = "github:nix-community/home-manager";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
2022-12-28 08:22:43 +00:00
2023-01-02 07:09:38 +00:00
nur.url = "github:nix-community/NUR";
2023-01-02 05:19:31 +00:00
2023-01-02 07:09:38 +00:00
utils.url = "github:gytis-ivaskevicius/flake-utils-plus";
2023-01-02 05:19:31 +00:00
2023-01-02 07:09:38 +00:00
nixos-wsl.url = "github:nix-community/nixos-wsl";
nixos-wsl.inputs.nixpkgs.follows = "nixpkgs";
nixos-wsl.inputs.flake-utils.follows = "utils";
};
outputs = {
self,
nixpkgs,
utils,
home-manager,
neovim,
nur,
nixos-wsl,
...
}: let
modules = {
home = {
common = [
./users/relms/base.nix
./users/relms/shell.nix
];
dev = [
./users/relms/dev.nix
];
gui = [
./users/relms/gui.nix
];
};
2023-01-02 07:09:38 +00:00
nixos = {
common = [
./common/personal.nix
./common/nix.nix
./devices/common.nix
];
dev = [
./common/dev/docker.nix
];
desktops = {
common = [
./common/desktop/apps.nix
./common/desktop/media.nix
./common/desktop/xorg.nix
];
gnome = [
./common/desktop/gnome.nix
];
};
};
};
pkgs = import nixpkgs {
system = "x86_64-linux";
overlays = [nur.overlay (utils.lib.genPkgOverlay neovim "neovim")];
};
in {
nixosConfigurations = {
skynet = nixpkgs.lib.nixosSystem {
inherit pkgs;
system = "x86_64-linux";
modules =
modules.nixos.common
++ modules.nixos.dev
++ modules.nixos.desktops.common
++ modules.nixos.desktops.gnome
++ [
./common/desktop/drivers/skynet.nix
./devices/skynet/base.nix
./devices/skynet/hardware.nix
];
};
2022-12-28 08:22:43 +00:00
2023-01-02 07:09:38 +00:00
wsl = nixpkgs.lib.nixosSystem {
inherit pkgs;
system = "x86_64-linux";
modules = [
nixos-wsl.nixosModules.wsl
./common/personal.nix
./common/nix.nix
./devices/wsl/base.nix
];
};
};
2022-12-31 09:27:24 +00:00
2023-01-02 07:09:38 +00:00
homeConfigurations.relms = home-manager.lib.homeManagerConfiguration {
inherit pkgs;
modules = modules.home.common ++ modules.home.dev ++ modules.home.gui;
2023-01-02 07:09:38 +00:00
};
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.alejandra;
};
2022-12-21 06:27:41 +00:00
}