126 lines
3.8 KiB
Nix
126 lines
3.8 KiB
Nix
{
|
|
description = "xyno doin nixos";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
|
nixpkgs-master.url = "github:nixos/nixpkgs?ref=master";
|
|
mobile-nixos.url = "github:mobile-nixos/mobile-nixos";
|
|
mobile-nixos.flake = false;
|
|
nix-flatpak.url = "github:gmodena/nix-flatpak?ref=latest";
|
|
home-manager.url = "github:nix-community/home-manager";
|
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
|
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
|
sops-nix.url = "github:Mic92/sops-nix";
|
|
sops-nix.inputs.nixpkgs.follows = "nixpkgs";
|
|
impermanence.url = "github:nix-community/impermanence";
|
|
|
|
# software
|
|
lanzaboote = {
|
|
url = "github:nix-community/lanzaboote/v0.4.2";
|
|
|
|
# Optional but recommended to limit the size of your system closure.
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
lix-module = {
|
|
url = "https://git.lix.systems/lix-project/nixos-module/archive/2.93.2-1.tar.gz";
|
|
# inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
zen-browser.url = "github:0xc000022070/zen-browser-flake";
|
|
zen-browser.inputs.nixpkgs.follows = "nixpkgs-master";
|
|
kmonad = {
|
|
url = "git+https://github.com/jokesper/kmonad?dir=nix&ref=feat-tap-overlap";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
niri.url = "github:YaLTeR/niri";
|
|
niri.inputs.nixpkgs.follows = "nixpkgs-master";
|
|
# nheko.url = "github:Nheko-Reborn/nheko";
|
|
# nheko.flake = false;
|
|
|
|
# helix
|
|
helix.url = "github:sofusa/helix-pull-diagnostics";
|
|
helix.inputs.nixpkgs.follows = "nixpkgs-master";
|
|
csharp-language-server.url = "github:sofusa/csharp-language-server";
|
|
csharp-language-server.inputs.nixpkgs.follows = "nixpkgs-master";
|
|
|
|
};
|
|
|
|
outputs =
|
|
inputs@{
|
|
self,
|
|
nixpkgs,
|
|
nixpkgs-master,
|
|
...
|
|
}:
|
|
let
|
|
lib = nixpkgs.lib.extend (
|
|
s: super: {
|
|
xyno = import ./lib {
|
|
inherit inputs nixpkgs self;
|
|
lib = s;
|
|
};
|
|
}
|
|
);
|
|
overlays = [
|
|
self.overlays.default
|
|
# lix-module.overlays.default
|
|
(
|
|
final: prev:
|
|
let
|
|
versionSuffix = "-horribly-patched";
|
|
lix = final.applyPatches {
|
|
name = "lix${versionSuffix}";
|
|
src = inputs.lix-module.inputs.lix;
|
|
patches = [
|
|
(final.fetchpatch {
|
|
name = "lix-2.93-structuredAttrs.patch";
|
|
url = "https://gerrit.lix.systems/changes/lix~3668/revisions/2/patch?download&raw";
|
|
hash = "sha256-JQlAU0texMa7DMrqk447SXJUEu1k4IP9z8mjCHyskVc=";
|
|
})
|
|
];
|
|
};
|
|
patchedOverlay = import (inputs.lix-module + "/overlay.nix") {
|
|
inherit versionSuffix lix;
|
|
};
|
|
in
|
|
patchedOverlay final prev
|
|
)
|
|
];
|
|
genPkgs =
|
|
system:
|
|
import nixpkgs {
|
|
inherit system overlays;
|
|
config.allowUnfree = true;
|
|
};
|
|
in
|
|
{
|
|
overlays.default = final: prev: {
|
|
unstable = import nixpkgs-master {
|
|
system = prev.system;
|
|
config.allowUnfree = true;
|
|
};
|
|
};
|
|
nixosConfigurations = lib.xyno.loadInstances ./instances (
|
|
[
|
|
# inputs.lix-module.nixosModules.default
|
|
inputs.kmonad.nixosModules.default
|
|
inputs.home-manager.nixosModules.default
|
|
inputs.lanzaboote.nixosModules.lanzaboote
|
|
inputs.sops-nix.nixosModules.sops
|
|
]
|
|
++ (import ./modules/module-list.nix)
|
|
);
|
|
devShell."x86_64-linux" =
|
|
let
|
|
pkgs = genPkgs "x86_64-linux";
|
|
in
|
|
pkgs.mkShell {
|
|
packages = [
|
|
pkgs.nixfmt-rfc-style
|
|
pkgs.nil
|
|
pkgs.sops
|
|
pkgs.ssh-to-age
|
|
];
|
|
SOPS_AGE_KEY_CMD = "";
|
|
};
|
|
};
|
|
}
|