fix: Everything

This commit is contained in:
Kat Inskip 2025-07-13 07:09:45 -07:00
parent fb814ed301
commit f6d114ebd0
Signed by: kat
GPG key ID: 465E64DECEA8CF0F
20 changed files with 415 additions and 1514 deletions

View file

@ -5,7 +5,6 @@
}: { }: {
nixpkgs = { nixpkgs = {
overlays = [ overlays = [
inputs.spacebar.overlay.${system}
]; ];
}; };
} }

1643
flake.lock generated

File diff suppressed because it is too large Load diff

192
flake.nix
View file

@ -1,41 +1,94 @@
{ {
description = "Kat's Infrastructure"; description = "Kat's Infrastructure";
inputs = { inputs = {
rust-overlay.url = "github:oxalica/rust-overlay"; nixpkgs-lib.url = "github:nix-community/nixpkgs.lib";
rust.url = "github:arcnmx/nixexprs-rust"; rust-overlay = {
treefmt-nix.url = "github:numtide/treefmt-nix"; url = "github:oxalica/rust-overlay";
inputs = {
nixpkgs.follows = "nixpkgs";
};
};
rust = {
url = "github:arcnmx/nixexprs-rust";
inputs = {
nixpkgs.follows = "nixpkgs";
};
};
treefmt-nix = {
url = "github:numtide/treefmt-nix";
inputs = {
nixpkgs.follows = "nixpkgs";
};
};
lix-module = { lix-module = {
url = "https://git.lix.systems/lix-project/nixos-module/archive/2.93.2-1.tar.gz"; url = "https://git.lix.systems/lix-project/nixos-module/archive/2.93.2-1.tar.gz";
inputs.nixpkgs.follows = "nixpkgs"; inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
};
}; };
systems.url = "github:nix-systems/default"; systems.url = "github:nix-systems/default";
# TODO: https://github.com/catppuccin/nix/issues/601 # TODO: https://github.com/catppuccin/nix/issues/601
catppuccin.url = "github:catppuccin/nix"; #/194881dd2ad6303bc2d49f9ce484d127372d7465"; catppuccin = {
flake-parts.url = "github:hercules-ci/flake-parts"; url = "github:catppuccin/nix";
inputs = {
nixpkgs.follows = "nixpkgs";
};
};
flake-parts = {
url = "github:hercules-ci/flake-parts";
inputs.nixpkgs-lib.follows = "nixpkgs-lib";
};
# to allow non-nix 2.4 evaluation # to allow non-nix 2.4 evaluation
flake-compat = { flake-compat = {
url = "github:edolstra/flake-compat"; url = "github:edolstra/flake-compat";
flake = false; flake = false;
}; };
rbw-bitw.url = "github:arcnmx/rbw/bitw-v1.12.x"; rbw-bitw = {
url = "github:arcnmx/rbw/bitw-v1.12.x";
inputs = {
nixpkgs.follows = "nixpkgs";
flakelib.follows = "flakelib";
rust.follows = "rust";
};
};
# better than nixpkgs.lib # better than nixpkgs.lib
std = { nix-std = {
url = "github:chessai/nix-std"; url = "github:chessai/nix-std";
}; };
nix-gaming.url = "github:fufexan/nix-gaming"; nix-gaming = {
url = "github:fufexan/nix-gaming";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-parts.follows = "flake-parts";
};
};
# used for overriding unwanted flake inputs # used for overriding unwanted flake inputs
empty.url = "github:input-output-hk/empty-flake"; empty.url = "github:input-output-hk/empty-flake";
# self-explanatory # self-explanatory
nixpkgs = { nixpkgs = {
url = "github:nixos/nixpkgs/nixos-unstable"; url = "github:nixos/nixpkgs/nixos-unstable";
}; };
clipboard-sync.url = "github:dnut/clipboard-sync"; clipboard-sync = {
nixpkgs-xr.url = "github:nix-community/nixpkgs-xr"; url = "github:dnut/clipboard-sync";
inputs = {
nixpkgs.follows = "nixpkgs";
};
};
nixpkgs-xr = {
url = "github:nix-community/nixpkgs-xr";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
flake-compat.follows = "flake-compat";
treefmt-nix.follows = "treefmt-nix";
};
};
infrastructure = { infrastructure = {
url = "github:gensokyo-zone/infrastructure/main"; url = "github:gensokyo-zone/infrastructure/main";
inputs = { inputs = {
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
nixpkgs-2405.follows = "empty";
arcexprs.follows = "arcexprs"; arcexprs.follows = "arcexprs";
flakelib.follows = "flakelib"; flakelib.follows = "flakelib";
sops-nix.follows = "sops-nix"; sops-nix.follows = "sops-nix";
@ -43,22 +96,53 @@
flake-utils.follows = "empty"; flake-utils.follows = "empty";
website.follows = "empty"; website.follows = "empty";
ci.follows = "empty"; ci.follows = "empty";
systemd2mqtt.follows = "empty";
deploy-rs.follows = "empty"; deploy-rs.follows = "empty";
flake-compat.follows = "empty"; flake-compat.follows = "empty";
barcodebuddy.follows = "empty"; barcodebuddy.follows = "empty";
tree.follows = "tree";
}; };
}; };
nixos-cli = { nixos-cli = {
type = "github"; type = "github";
owner = "nix-community"; owner = "nix-community";
repo = "nixos-cli"; repo = "nixos-cli";
inputs.nixpkgs.follows = "nixpkgs"; inputs = {
nixpkgs.follows = "nixpkgs";
flake-compat.follows = "flake-compat";
nix-options-doc.follows = "empty";
};
};
chaotic = {
url = "github:chaotic-cx/nyx/nyxpkgs-unstable";
inputs = {
nixpkgs.follows = "nixpkgs";
rust-overlay.follows = "rust-overlay";
home-manager.follows = "home-manager";
};
};
flake-utils-plus = {
url = "github:gytis-ivaskevicius/flake-utils-plus";
inputs = {
flake-utils.follows = "flake-utils";
};
}; };
chaotic.url = "github:chaotic-cx/nyx/nyxpkgs-unstable";
solaar = { solaar = {
# ewww flakehub ;; # ewww flakehub ;;
url = "https://flakehub.com/f/Svenum/Solaar-flake/*.tar.gz"; url = "https://flakehub.com/f/Svenum/Solaar-flake/*.tar.gz";
inputs.nixpkgs.follows = "nixpkgs"; inputs = {
nixpkgs.follows = "nixpkgs";
flake-compat.follows = "flake-compat";
snowfall-lib.follows = "snowfall-lib";
};
};
snowfall-lib = {
url = "github:snowfallorg/lib";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils-plus.follows = "flake-utils-plus";
flake-compat.follows = "flake-compat";
};
}; };
nh = { nh = {
url = "github:nix-community/nh"; url = "github:nix-community/nh";
@ -69,25 +153,25 @@
inputs = { inputs = {
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
nixpkgs-stable.follows = "nixpkgs"; nixpkgs-stable.follows = "nixpkgs";
niri-stable.follows = "empty";
xwayland-satellite-stable.follows = "empty";
}; };
}; };
moonlight = { moonlight = {
url = "github:moonlight-mod/moonlight"; url = "github:moonlight-mod/moonlight";
inputs.nixpkgs.follows = "nixpkgs";
};
hyprlock = {
url = "github:hyprwm/hyprlock";
inputs = { inputs = {
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
systems.follows = "systems"; flake-utils.follows = "flake-utils";
}; };
}; };
lanzaboote = { lanzaboote = {
url = "github:nix-community/lanzaboote/v0.4.2"; url = "github:nix-community/lanzaboote/v0.4.2";
inputs = { inputs = {
flake-parts.follows = "flake-parts";
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
flake-compat.follows = "flake-compat"; flake-compat.follows = "flake-compat";
rust-overlay.follows = "rust-overlay";
}; };
}; };
catppuccin-qtct = { catppuccin-qtct = {
@ -96,12 +180,25 @@
repo = "qt5ct"; repo = "qt5ct";
flake = false; flake = false;
}; };
spicetify-nix.url = "github:Gerg-L/spicetify-nix"; spicetify-nix = {
url = "github:Gerg-L/spicetify-nix";
inputs = {
systems.follows = "systems";
nixpkgs.follows = "nixpkgs";
};
};
naersk = {
url = "github:nix-community/naersk";
inputs = {
nixpkgs.follows = "nixpkgs";
};
};
push2talk = { push2talk = {
url = "github:cyrinux/push2talk/main"; url = "github:cyrinux/push2talk/main";
inputs = { inputs = {
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils"; flake-utils.follows = "flake-utils";
naersk.follows = "naersk";
}; };
}; };
wezterm = { wezterm = {
@ -109,19 +206,20 @@
inputs = { inputs = {
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils"; flake-utils.follows = "flake-utils";
rust-overlay.follows = "rust-overlay";
}; };
}; };
ci = { ci = {
url = "github:arcnmx/ci/v0.7"; url = "github:arcnmx/ci/v0.7";
flake = false; flake = false;
}; };
flakelibstd = { std = {
url = "github:flakelib/std"; url = "github:flakelib/std";
inputs.nix-std.follows = "std"; inputs.nix-std.follows = "nix-std";
}; };
flakelib = { flakelib = {
url = "github:flakelib/fl"; url = "github:flakelib/fl";
inputs.std.follows = "flakelibstd"; inputs.std.follows = "std";
}; };
# deployments # deployments
deploy-rs = { deploy-rs = {
@ -144,23 +242,40 @@
url = "github:lnl7/nix-darwin/master"; url = "github:lnl7/nix-darwin/master";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
# status bar
spacebar = {
url = "github:cmacrae/spacebar/v1.4.0";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
};
};
flake-utils = { flake-utils = {
url = "github:numtide/flake-utils"; url = "github:numtide/flake-utils";
inputs.systems.follows = "systems"; inputs.systems.follows = "systems";
}; };
neorg-overlay.url = "github:nvim-neorg/nixpkgs-neorg-overlay"; neorg-overlay = {
url = "github:nvim-neorg/nixpkgs-neorg-overlay";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
norg.follows = "norg";
norg-meta.follows = "norg-meta";
};
};
norg = {
url = "github:kittywitch/tree-sitter-norg/dev";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
flake-compat.follows = "flake-compat";
};
};
norg-meta = {
url = "github:kittywitch/tree-sitter-norg-meta";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
flake-compat.follows = "flake-compat";
};
};
# file structure -> attrset # file structure -> attrset
tree = { tree = {
url = "github:kittywitch/tree"; url = "github:kittywitch/tree";
inputs = { inputs = {
nix-std.follows = "nix-std";
std.follows = "std"; std.follows = "std";
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
}; };
@ -197,7 +312,7 @@
}; };
# a bunch of modules (also arcnmx is good) # a bunch of modules (also arcnmx is good)
arcexprs = { arcexprs = {
url = "github:arcnmx/nixexprs/master"; url = "github:kittywitch/arcexprs/master";
}; };
base16 = { base16 = {
url = "github:arcnmx/base16.nix/flake"; url = "github:arcnmx/base16.nix/flake";
@ -214,15 +329,14 @@
flakelib.follows = "flakelib"; flakelib.follows = "flakelib";
}; };
}; };
# plasma manager nur = {
plasma-manager = { url = "github:nix-community/NUR";
url = "github:pjones/plasma-manager";
inputs = { inputs = {
nixpkgs.follows = "nixpkgs"; nixpkgs.follows = "nixpkgs";
home-manager.follows = "home-manager"; treefmt-nix.follows = "treefmt-nix";
flake-parts.follows = "flake-parts";
}; };
}; };
nur.url = "github:nix-community/NUR";
}; };
outputs = inputs: import ./outputs.nix {inherit inputs;}; outputs = inputs: import ./outputs.nix {inherit inputs;};
} }

View file

@ -1,7 +1,4 @@
{ {config, ...}: let
config,
...
}: let
inherit (config.catppuccin) sources; inherit (config.catppuccin) sources;
cfg = config.catppuccin.sway; cfg = config.catppuccin.sway;
theme = "${sources.sway}/catppuccin-${cfg.flavor}"; theme = "${sources.sway}/catppuccin-${cfg.flavor}";

View file

@ -1,4 +1,5 @@
{ {
config,
lib, lib,
pkgs, pkgs,
inputs, inputs,
@ -181,8 +182,6 @@ in {
gnomeShellTheme = mkForce false; gnomeShellTheme = mkForce false;
}; };
}; };
dconf.settings = mkForce {};
gtk.enable = true;
# https://git.gay/olivia/fur/src/branch/main/modules/home/theming/qt/default.nix # https://git.gay/olivia/fur/src/branch/main/modules/home/theming/qt/default.nix
qt = { qt = {
enable = true; enable = true;

View file

@ -1,7 +1,4 @@
{ {pkgs, ...}: {
pkgs,
...
}: {
home.packages = with pkgs; [ home.packages = with pkgs; [
(discord-krisp.override { (discord-krisp.override {
withOpenASAR = true; withOpenASAR = true;

View file

@ -1,13 +1,9 @@
_: { { config, ... }: {
environment.etc."ssl/credentials_template".text = ''
CF_API_EMAIL=!!CLOUDFLARE_EMAIL!!
CLOUDFLARE_API_KEY=!!CLOUDFLARE_API_KEY!!
'';
security.acme = { security.acme = {
defaults = { defaults = {
dnsProvider = "cloudflare"; dnsProvider = "cloudflare";
email = "acme@inskip.me"; email = "acme@inskip.me";
credentialsFile = config.sops.secrets.acme_credentials.path;
}; };
acceptTerms = true; acceptTerms = true;
}; };

View file

@ -1,12 +0,0 @@
{config, ...}: {
scalpel.trafos."credentials_file" = {
source = "/etc/ssl/credentials_template";
matchers."CLOUDFLARE_EMAIL".secret = config.sops.secrets.cloudflare_email.path;
matchers."CLOUDFLARE_API_KEY".secret = config.sops.secrets.cloudflare_api_key.path;
owner = "acme";
group = "acme";
mode = "0440";
};
security.acme.defaults.credentialsFile = config.scalpel.trafos."credentials_file".destination;
}

View file

@ -4,10 +4,5 @@ _: let
sopsFile = ./secrets.yaml; sopsFile = ./secrets.yaml;
}; };
in { in {
sops.secrets.cloudflare_email = secretConfig; sops.secrets.acme_credentials = secretConfig;
sops.secrets.cloudflare_api_key = secretConfig;
scalpels = [
./scalpel.nix
];
} }

View file

@ -1,5 +1,4 @@
cloudflare_email: ENC[AES256_GCM,data:fwcHkWRqH3hEPDbFmA==,iv:He6yJHpD9oXrZSHPJKL7mnkRWm621HRj2cS6qLSn6aI=,tag:lON1D+55zSiJQljTox2JKQ==,type:str] acme_credentials: ENC[AES256_GCM,data:hYjKLjGWMq9PiCobwo7PCWa/VF0ifJmLOrU4BP+vQMCFn19Ukl1gLnbDrLLzXfg9nAhkMGn5FiQJwl06ZX8E4qELXGkzSuLMvyDioEi6Plev/Wmx9szkCUd5,iv:hplC4l+aVnTLKH+bJZHCU2+NHh6154yPGMyozCUzwjM=,tag:bgOBFauegLvbFWc9sK0rcg==,type:str]
cloudflare_api_key: ENC[AES256_GCM,data:kCDaXb1BPWoNVFVRjfOw4577BlIbMtsaouRT8dwNiL/JGNWH9w==,iv:rKSpeSfjIiQNFu58qjNnUtdBPIfXhIa6u7G7wqBohSg=,tag:7wnoB1MBj55okWzNISKftA==,type:str]
sops: sops:
shamir_threshold: 1 shamir_threshold: 1
age: age:
@ -84,8 +83,8 @@ sops:
UjBkbHZQQS9HNkN0b01leDRKVDhNT1EKIUPRptezUIjnW0eYzRIf6qvRq5WIqBNo UjBkbHZQQS9HNkN0b01leDRKVDhNT1EKIUPRptezUIjnW0eYzRIf6qvRq5WIqBNo
OCglfk20EI/r58nuJMiMUwEfKpn9Y9FhaML8eXjZ7sU4aeS82cDICA== OCglfk20EI/r58nuJMiMUwEfKpn9Y9FhaML8eXjZ7sU4aeS82cDICA==
-----END AGE ENCRYPTED FILE----- -----END AGE ENCRYPTED FILE-----
lastmodified: "2023-04-27T01:10:09Z" lastmodified: "2025-07-13T12:22:35Z"
mac: ENC[AES256_GCM,data:tsvbspqI3jrwWQ/728g+urvhbDTvYJ70rcW1F3w5hC0YR6n7M4oED+QXOoH437Q85A9168OvfNqoIIIq3zEq7OWhk1dtInW2EWh2j5nHz1aFkiYg7VonfktJN9ylyamuZVKkmarMc87thzZrU+Ntb2VOdYsYd0AdWtlfY1CT++4=,iv:TI7tUjAUNc6DxpPRrrEdrsWxiJP6F+BZLGaOzTyo+3I=,tag:2zbq3/rMWFNjkRoBnYgfEA==,type:str] mac: ENC[AES256_GCM,data:MXKAesYZVdW9N1BOeNqXi8IkBjWLw1VLgXwanaM0cHe63iS17VegEGhZet0WgiMuvcroPKRNzkRSXmv8pgLsaoVMAswgJAEGJjiVDMUKnvuMd7jIs9PYp16k94VRdl/eEmVUhEmXnfpNI4QeASDbxgbRuRFIXUqGYvqYj+FlJcE=,iv:RejxH3dUgj1oxzMnMeYZ5T+XXCbbPzsyAFGyUIKcrz8=,tag:bGaOeEnvqiOAVMLzTIxS5w==,type:str]
pgp: pgp:
- created_at: "2025-06-27T20:11:22Z" - created_at: "2025-06-27T20:11:22Z"
enc: |- enc: |-
@ -108,4 +107,4 @@ sops:
-----END PGP MESSAGE----- -----END PGP MESSAGE-----
fp: CD8CE78CB0B3BDD4 fp: CD8CE78CB0B3BDD4
unencrypted_suffix: _unencrypted unencrypted_suffix: _unencrypted
version: 3.7.3 version: 3.10.2

View file

@ -1,24 +0,0 @@
{pkgs, ...}: {
home-manager.users.kat.programs.weechat = {
scripts = with pkgs.weechatScripts; [
weechat-matrix
];
plugins = {
python = {
packages = ["weechat-matrix"];
};
};
config.matrix = {
network = {
max_backlog_sync_events = 30;
lazy_load_room_users = true;
autoreconnect_delay_max = 5;
lag_min-show = 1000;
};
look = {
server_buffer = "independent";
redactions = "notice";
};
};
};
}

View file

@ -1,11 +1,11 @@
{pkgs, ...}: { {pkgs, inputs, ...}: {
home-manager.users.kat.programs.weechat = { home-manager.users.kat.programs.weechat = {
plugins = { plugins = {
perl = { perl = {
enable = true; enable = true;
}; };
}; };
scripts = with pkgs.weechatScripts; [ scripts = with inputs.arcexprs.legacyPackages.${pkgs.system}.weechatScripts; with pkgs.weechatScripts; [
highmon highmon
parse_relayed_msg parse_relayed_msg
]; ];

View file

@ -15,7 +15,7 @@ in {
enable = true; enable = true;
}; };
}; };
scripts = with pkgs.weechatScripts; [ scripts = with inputs.arcexprs.legacyPackages.${pkgs.system}.weechatScripts; with pkgs.weechatScripts; [
colorize_nicks colorize_nicks
title title
weechat-go weechat-go

View file

@ -14,7 +14,7 @@ in
{ {
inherit inputs tree std pkgs lib; inherit inputs tree std pkgs lib;
legacyPackages = pkgs; legacyPackages = pkgs;
packages = set.merge [pkgs wrappers.packages]; #packages = set.merge [pkgs wrappers.packages];
checks = checks // formatting.checks; checks = checks // formatting.checks;
inherit (formatting) formatter; inherit (formatting) formatter;
} }

View file

@ -4,6 +4,6 @@
... ...
}: _: prev: let }: _: prev: let
# formerly final: prev:, but deadnix # formerly final: prev:, but deadnix
inherit (inputs.std.lib) set; inherit (inputs.std.lib.Std.compat) set;
in in
set.map (_: package: prev.callPackage package {}) (removeAttrs tree.packages ["default"]) set.map (_: package: prev.callPackage package {}) (removeAttrs tree.packages ["default"])

View file

@ -1,6 +1,6 @@
{inputs, ...}: let {inputs, ...}: let
std = let std = let
baseStd = inputs.std.lib; baseStd = inputs.std.lib.Std.compat // { inherit (inputs.std.lib.Std.std) tuple; };
inherit (baseStd) set function list bool types optional tuple; inherit (baseStd) set function list bool types optional tuple;
mergeWith = let mergeWith = let
append = { append = {

View file

@ -13,9 +13,6 @@ _: let
]) ])
++ (with tree.nixos.hardware; [ ++ (with tree.nixos.hardware; [
oracle_micro oracle_micro
])
++ (with tree.nixos.servers; [
rustdesk
]); ]);
system.stateVersion = "23.11"; system.stateVersion = "23.11";

View file

@ -109,7 +109,6 @@
external = with inputs; external = with inputs;
[ [
nix-index-database.hmModules.nix-index nix-index-database.hmModules.nix-index
plasma-manager.homeManagerModules.plasma-manager
base16.homeModules.base16 base16.homeModules.base16
catppuccin.homeModules.catppuccin catppuccin.homeModules.catppuccin
inputs.sops-nix.homeManagerModules.sops inputs.sops-nix.homeManagerModules.sops

View file

@ -1,5 +1,5 @@
{inputs, ...}: let {inputs, ...}: let
inherit (inputs.std.lib) string set; inherit (inputs.std.lib.Std.compat) string set;
inherit (inputs.self) systems; inherit (inputs.self) systems;
enabledNixosSystems = set.filter (_: system: system.config.ci.enable && system.config.type == "NixOS") systems; enabledNixosSystems = set.filter (_: system: system.config.ci.enable && system.config.type == "NixOS") systems;
in { in {

View file

@ -7,7 +7,7 @@
exportFile = import ./exports.nix args; exportFile = import ./exports.nix args;
inherit (exportFile) exports; inherit (exportFile) exports;
inherit (lib.strings) makeBinPath; inherit (lib.strings) makeBinPath;
inherit (inputs.std.lib) string; inherit (inputs.std.lib.Std.compat) string;
inherit (inputs.self.legacyPackages.${system}) pkgs; inherit (inputs.self.legacyPackages.${system}) pkgs;
inherit (import ../ci/nix.nix) ci; inherit (import ../ci/nix.nix) ci;
nf-generate = pkgs.writeShellScriptBin "nf-generate" '' nf-generate = pkgs.writeShellScriptBin "nf-generate" ''