diff --git a/flake.nix b/flake.nix index e437f86..2bf01ca 100644 --- a/flake.nix +++ b/flake.nix @@ -21,13 +21,14 @@ }; outputs = - { self - , nixpkgs - , nixpkgs-stable - , sops-nix - , ghettoptt - , huecli - , ... + { + self, + nixpkgs, + nixpkgs-stable, + sops-nix, + ghettoptt, + huecli, + ... }@inputs: let system = "x86_64-linux"; @@ -44,54 +45,69 @@ "x86_64-darwin" "aarch64-darwin" ]; - forAllSystems = f: nixpkgs.lib.genAttrs allSystems (system: f { - pkgs = import nixpkgs { inherit system; }; - }); + forAllSystems = + f: nixpkgs.lib.genAttrs allSystems (system: f { pkgs = import nixpkgs { inherit system; }; }); in { nixosConfigurations = { prismo = nixpkgs.lib.nixosSystem { inherit system; - specialArgs = { inherit inputs self user; }; + specialArgs = { + inherit inputs self user; + }; modules = [ ./hosts/prismo ]; }; magicman = nixpkgs.lib.nixosSystem { inherit system; - specialArgs = { inherit inputs self user; }; + specialArgs = { + inherit inputs self user; + }; modules = [ - ({ config, pkgs, ... }: { - nixpkgs.overlays = [ - overlay-stable - ghettoptt.overlays.default - huecli.overlays.default - ]; - }) + ( + { config, pkgs, ... }: + { + nixpkgs.overlays = [ + overlay-stable + ghettoptt.overlays.default + huecli.overlays.default + ]; + } + ) ./hosts/magicman sops-nix.nixosModules.sops ]; }; gunter = nixpkgs.lib.nixosSystem { inherit system; - specialArgs = { inherit inputs self user sops-nix; }; + specialArgs = { + inherit + inputs + self + user + sops-nix + ; + }; modules = [ - ({ config, pkgs, ... }: { - nixpkgs.overlays = [ - overlay-stable - ghettoptt.overlays.default - huecli.overlays.default - ]; - }) + ( + { config, pkgs, ... }: + { + nixpkgs.overlays = [ + overlay-stable + ghettoptt.overlays.default + huecli.overlays.default + ]; + } + ) ./hosts/gunter sops-nix.nixosModules.sops ]; }; }; - devShells = forAllSystems ({ pkgs }: { - default = pkgs.mkShell { - packages = with pkgs; [ - pre-commit - ]; - }; - }); + devShells = forAllSystems ( + { pkgs }: + { + default = pkgs.mkShell { packages = with pkgs; [ pre-commit ]; }; + } + ); }; } diff --git a/home/editor/neovim/default.nix b/home/editor/neovim/default.nix index 1966671..a69e9d3 100644 --- a/home/editor/neovim/default.nix +++ b/home/editor/neovim/default.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ programs = { neovim = { enable = true; diff --git a/home/gunter.nix b/home/gunter.nix index 862d409..a2f1b6f 100644 --- a/home/gunter.nix +++ b/home/gunter.nix @@ -1,38 +1,48 @@ -{ pkgs, inputs, user, ... }: { +{ + pkgs, + inputs, + user, + ... +}: +{ imports = [ inputs.home-manager.nixosModules.home-manager ]; home-manager = { useUserPackages = true; useGlobalPkgs = true; - extraSpecialArgs = { inherit pkgs inputs user; }; - users.${user} = { pkgs, ... }: { - imports = [ - inputs.sops-nix.homeManagerModules.sops - ./sops - ./editor/neovim - ./programs/firefox - ./programs/tmux - ./programs/dunst - ./programs/kitty - ./programs/rofi - ./programs/obs-studio - ./programs/vscode - ./scripts - ./zsh - ./packages - ./hyprland/gunter.nix - ./ssh - ./services/backup-home.nix - ./services/ghettoptt.nix - ]; - firefox.enable = true; - tmux.enable = true; - hyprland.enable = true; - home = { - username = "${user}"; - homeDirectory = "/home/${user}"; - stateVersion = "23.11"; - }; - programs.home-manager.enable = true; + extraSpecialArgs = { + inherit pkgs inputs user; }; + users.${user} = + { pkgs, ... }: + { + imports = [ + inputs.sops-nix.homeManagerModules.sops + ./sops + ./editor/neovim + ./programs/firefox + ./programs/tmux + ./programs/dunst + ./programs/kitty + ./programs/rofi + ./programs/obs-studio + ./programs/vscode + ./scripts + ./zsh + ./packages + ./hyprland/gunter.nix + ./ssh + ./services/backup-home.nix + ./services/ghettoptt.nix + ]; + firefox.enable = true; + tmux.enable = true; + hyprland.enable = true; + home = { + username = "${user}"; + homeDirectory = "/home/${user}"; + stateVersion = "23.11"; + }; + programs.home-manager.enable = true; + }; }; } diff --git a/home/hyprland/cursor.nix b/home/hyprland/cursor.nix index a7870a2..ef279c2 100644 --- a/home/hyprland/cursor.nix +++ b/home/hyprland/cursor.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ home.pointerCursor = { gtk.enable = true; # x11.enable = true; diff --git a/home/hyprland/gunter.nix b/home/hyprland/gunter.nix index 81466b5..9d5365b 100644 --- a/home/hyprland/gunter.nix +++ b/home/hyprland/gunter.nix @@ -1 +1,8 @@ -{ imports = [ ./hyprland_gunter.nix ./waybar ./xdg.nix ./cursor.nix ]; } +{ + imports = [ + ./hyprland_gunter.nix + ./waybar + ./xdg.nix + ./cursor.nix + ]; +} diff --git a/home/hyprland/hypridle.nix b/home/hyprland/hypridle.nix index 8def097..e745c52 100644 --- a/home/hyprland/hypridle.nix +++ b/home/hyprland/hypridle.nix @@ -1,8 +1,12 @@ -{ config, osConfig, pkgs, ... }: { +{ + config, + osConfig, + pkgs, + ... +}: +{ - home.packages = with pkgs; [ - hypridle - ]; + home.packages = with pkgs; [ hypridle ]; xdg.configFile = { "hypr/hypridle.conf" = { source = config.lib.file.mkOutOfStoreSymlink ./. + "/hypridle_${osConfig.system.name}.conf"; diff --git a/home/hyprland/hyprland_gunter.nix b/home/hyprland/hyprland_gunter.nix index ac2e280..e3719f6 100644 --- a/home/hyprland/hyprland_gunter.nix +++ b/home/hyprland/hyprland_gunter.nix @@ -1,4 +1,11 @@ -{ inputs, pkgs, lib, config, ... }: { +{ + inputs, + pkgs, + lib, + config, + ... +}: +{ imports = [ ./hyprlock.nix ./hypridle.nix @@ -121,9 +128,7 @@ "special:special, on-created-empty:kitty, rounding:true, decorate:false, border:false" ]; - bindm = [ - "ALT,mouse:272,movewindow" - ]; + bindm = [ "ALT,mouse:272,movewindow" ]; bindr = [ # mumble ptt release diff --git a/home/hyprland/hyprland_magicman.nix b/home/hyprland/hyprland_magicman.nix index 4e930b9..1e14ab4 100644 --- a/home/hyprland/hyprland_magicman.nix +++ b/home/hyprland/hyprland_magicman.nix @@ -1,4 +1,11 @@ -{ inputs, pkgs, lib, config, ... }: { +{ + inputs, + pkgs, + lib, + config, + ... +}: +{ imports = [ ./hyprlock.nix ./hypridle.nix @@ -30,17 +37,13 @@ "$shiftMainMod" = "SUPER_SHIFT"; "$term" = "kitty"; - monitor = [ - "eDP-1,1920x1080@60,0x0,1" - ]; + monitor = [ "eDP-1,1920x1080@60,0x0,1" ]; input = { kb_layout = "no"; follow_mouse = 1; }; - env = [ - "XDG_SESSION_TYPE,wayland" - ]; + env = [ "XDG_SESSION_TYPE,wayland" ]; decoration = { rounding = 10; @@ -97,9 +100,7 @@ "special:special, on-created-empty:kitty, rounding:true, decorate:false, border:false" ]; - bindm = [ - "ALT,mouse:272,movewindow" - ]; + bindm = [ "ALT,mouse:272,movewindow" ]; bindr = [ # mumble ptt release diff --git a/home/hyprland/hyprland_prismo.nix b/home/hyprland/hyprland_prismo.nix index f5f6197..c700884 100644 --- a/home/hyprland/hyprland_prismo.nix +++ b/home/hyprland/hyprland_prismo.nix @@ -1,4 +1,11 @@ -{ inputs, pkgs, lib, config, ... }: { +{ + inputs, + pkgs, + lib, + config, + ... +}: +{ options.hyprland.enable = lib.mkEnableOption "Hyprland"; config = { home.packages = with pkgs; [ @@ -26,17 +33,13 @@ "$shiftMainMod" = "SUPER_SHIFT"; "$term" = "kitty"; - - monitor = [ - ]; + monitor = [ ]; input = { kb_layout = "no"; follow_mouse = 1; }; - env = [ - "XDG_SESSION_TYPE,wayland" - ]; + env = [ "XDG_SESSION_TYPE,wayland" ]; decoration = { rounding = 0; @@ -92,9 +95,7 @@ "name:main 2, monitor:$mon_center, persistent:true, default:true" ]; - bindm = [ - "ALT,mouse:272,movewindow" - ]; + bindm = [ "ALT,mouse:272,movewindow" ]; bindr = [ # mumble ptt release diff --git a/home/hyprland/hyprlock.nix b/home/hyprland/hyprlock.nix index f9b52fc..b841b16 100644 --- a/home/hyprland/hyprlock.nix +++ b/home/hyprland/hyprlock.nix @@ -1,8 +1,12 @@ -{ config, osConfig, pkgs, ... }: { +{ + config, + osConfig, + pkgs, + ... +}: +{ - home.packages = with pkgs; [ - hyprlock - ]; + home.packages = with pkgs; [ hyprlock ]; xdg.configFile = { "hypr/hyprlock.conf" = { source = config.lib.file.mkOutOfStoreSymlink ./. + "/hyprlock_${osConfig.system.name}.conf"; diff --git a/home/hyprland/magicman.nix b/home/hyprland/magicman.nix index 3a1d95c..5657853 100644 --- a/home/hyprland/magicman.nix +++ b/home/hyprland/magicman.nix @@ -1 +1,8 @@ -{ imports = [ ./hyprland_magicman.nix ./waybar ./xdg.nix ./cursor.nix ]; } +{ + imports = [ + ./hyprland_magicman.nix + ./waybar + ./xdg.nix + ./cursor.nix + ]; +} diff --git a/home/hyprland/prismo.nix b/home/hyprland/prismo.nix index 85a3f8d..5ecd4ac 100644 --- a/home/hyprland/prismo.nix +++ b/home/hyprland/prismo.nix @@ -1 +1,8 @@ -{ imports = [ ./hyprland_prismo.nix ./waybar ./xdg.nix ./cursor.nix ]; } +{ + imports = [ + ./hyprland_prismo.nix + ./waybar + ./xdg.nix + ./cursor.nix + ]; +} diff --git a/home/hyprland/waybar/default.nix b/home/hyprland/waybar/default.nix index 494fe5b..9126a7b 100644 --- a/home/hyprland/waybar/default.nix +++ b/home/hyprland/waybar/default.nix @@ -1,4 +1,9 @@ -{ pkgs, lib, osConfig, ... }: +{ + pkgs, + lib, + osConfig, + ... +}: let flakestat = pkgs.writeShellApplication { name = "flakestat"; @@ -11,9 +16,7 @@ let arrhist = pkgs.stdenv.mkDerivation { name = "arrhist"; propagatedBuildInputs = [ - (pkgs.python3.withPackages (pythonPackages: with pythonPackages; [ - requests - ])) + (pkgs.python3.withPackages (pythonPackages: with pythonPackages; [ requests ])) ]; src = ./arrhist.py; dontUnpack = true; @@ -29,13 +32,14 @@ in sops.secrets."radarr_api_key" = { }; xdg.configFile."waybar/macchiato.css" = { - source = pkgs.fetchFromGitHub - { + source = + pkgs.fetchFromGitHub { owner = "catppuccin"; repo = "waybar"; rev = "f74ab1eecf2dcaf22569b396eed53b2b2fbe8aff"; sha256 = "WLJMA2X20E5PCPg0ZPtSop0bfmu+pLImP9t8A8V4QK8="; - } + "/themes/macchiato.css"; + } + + "/themes/macchiato.css"; }; programs.waybar = { @@ -165,17 +169,16 @@ in "position" = "top"; modules-left = [ "custom/flakestat" ]; modules-center = [ "hyprland/workspaces" ]; - modules-right = - [ - (lib.mkIf (withArrhist) "custom/arrhist") - "pulseaudio" - "pulseaudio#microphone" - "memory" - "cpu" - (lib.mkIf (withBattery) "battery") - "clock" - "tray" - ]; + modules-right = [ + (lib.mkIf (withArrhist) "custom/arrhist") + "pulseaudio" + "pulseaudio#microphone" + "memory" + "cpu" + (lib.mkIf (withBattery) "battery") + "clock" + "tray" + ]; "hyprland/workspaces" = { "format" = "{name}"; "on-click" = "activate"; @@ -186,7 +189,13 @@ in "scroll-step" = 5; "format" = "{icon} {volume}%"; "format-muted" = ""; - "format-icons" = { "default" = [ "" "" "" ]; }; + "format-icons" = { + "default" = [ + "" + "" + "" + ]; + }; "on-scroll-up" = "pamixer -i ${volInterval}"; "on-scroll-down" = "pamixer -d ${volInterval}"; "on-click" = "pamixer -t"; @@ -209,7 +218,9 @@ in "memory" = { "interval" = 3; "format" = " {percentage}%"; - "states" = { "warning" = 85; }; + "states" = { + "warning" = 85; + }; }; "cpu" = { "interval" = 3; @@ -240,7 +251,8 @@ in "return-type" = "json"; "interval" = 600; }; - } // lib.optionalAttrs (withArrhist) { + } + // lib.optionalAttrs (withArrhist) { "custom/arrhist" = { "exec" = "${arrhist}/bin/arrhist"; "return-type" = "json"; diff --git a/home/hyprland/xdg.nix b/home/hyprland/xdg.nix index ddcac6b..2b71d6a 100644 --- a/home/hyprland/xdg.nix +++ b/home/hyprland/xdg.nix @@ -1,4 +1,5 @@ -{ config, ... }: { +{ config, ... }: +{ xdg.configFile = { "hypr/hyprpaper.conf" = { source = config.lib.file.mkOutOfStoreSymlink ./. + "/hyprpaper.conf"; diff --git a/home/i3/default.nix b/home/i3/default.nix index ad061de..c035be2 100644 --- a/home/i3/default.nix +++ b/home/i3/default.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let mod = "Mod4"; in diff --git a/home/magicman.nix b/home/magicman.nix index 965e0af..e1d40f2 100644 --- a/home/magicman.nix +++ b/home/magicman.nix @@ -1,39 +1,49 @@ -{ pkgs, inputs, user, ... }: { +{ + pkgs, + inputs, + user, + ... +}: +{ imports = [ inputs.home-manager.nixosModules.home-manager ]; home-manager = { useUserPackages = true; useGlobalPkgs = true; - extraSpecialArgs = { inherit pkgs inputs user; }; - users.${user} = { pkgs, ... }: { - imports = [ - inputs.sops-nix.homeManagerModules.sops - ./sops - ./editor/neovim - ./programs/firefox - ./programs/tmux - ./programs/dunst - ./programs/kitty - ./programs/rofi - ./programs/obs-studio - ./programs/vscode - ./programs/pywal - ./programs/zellij - ./scripts - ./scripts/batlvl.nix - ./zsh - ./packages - ./hyprland/magicman.nix - ./ssh - ]; - firefox.enable = true; - tmux.enable = true; - hyprland.enable = true; - home = { - username = "${user}"; - homeDirectory = "/home/${user}"; - stateVersion = "23.11"; - }; - programs.home-manager.enable = true; + extraSpecialArgs = { + inherit pkgs inputs user; }; + users.${user} = + { pkgs, ... }: + { + imports = [ + inputs.sops-nix.homeManagerModules.sops + ./sops + ./editor/neovim + ./programs/firefox + ./programs/tmux + ./programs/dunst + ./programs/kitty + ./programs/rofi + ./programs/obs-studio + ./programs/vscode + ./programs/pywal + ./programs/zellij + ./scripts + ./scripts/batlvl.nix + ./zsh + ./packages + ./hyprland/magicman.nix + ./ssh + ]; + firefox.enable = true; + tmux.enable = true; + hyprland.enable = true; + home = { + username = "${user}"; + homeDirectory = "/home/${user}"; + stateVersion = "23.11"; + }; + programs.home-manager.enable = true; + }; }; } diff --git a/home/packages/default.nix b/home/packages/default.nix index e2eeda1..47fa03d 100644 --- a/home/packages/default.nix +++ b/home/packages/default.nix @@ -79,10 +79,12 @@ in typescript # Py stuff - (python312.withPackages (p: with p; [ - requests - ipython - ])) + (python312.withPackages ( + p: with p; [ + requests + ipython + ] + )) poetry ruff @@ -97,16 +99,10 @@ in # Stuff with overrides # Blender - (blender.override { - cudaSupport = withCuda; - }) + (blender.override { cudaSupport = withCuda; }) # Btop - (btop.override { - cudaSupport = withCuda; - }) + (btop.override { cudaSupport = withCuda; }) # PrismLauncher - (prismlauncher.override { - withWaylandGLFW = true; - }) + (prismlauncher.override { withWaylandGLFW = true; }) ]; } diff --git a/home/prismo.nix b/home/prismo.nix index 5ce15d2..35a9ccf 100644 --- a/home/prismo.nix +++ b/home/prismo.nix @@ -1,38 +1,48 @@ -{ pkgs, inputs, user, ... }: { +{ + pkgs, + inputs, + user, + ... +}: +{ imports = [ inputs.home-manager.nixosModules.home-manager ]; home-manager = { useUserPackages = true; useGlobalPkgs = true; - extraSpecialArgs = { inherit pkgs inputs user; }; - users.${user} = { pkgs, ... }: { - imports = [ - inputs.sops-nix.homeManagerModules.sops - ./sops - ./editor/neovim - ./programs/firefox - ./programs/tmux - ./programs/dunst - ./programs/kitty - ./programs/rofi - ./programs/obs-studio - ./programs/vscode - ./scripts - ./zsh - ./packages - ./hyprland - ./ssh - ./services/backup-home.nix - ./services/ghettoptt.nix - ]; - firefox.enable = true; - tmux.enable = true; - hyprland.enable = true; - home = { - username = "${user}"; - homeDirectory = "/home/${user}"; - stateVersion = "23.11"; - }; - programs.home-manager.enable = true; + extraSpecialArgs = { + inherit pkgs inputs user; }; + users.${user} = + { pkgs, ... }: + { + imports = [ + inputs.sops-nix.homeManagerModules.sops + ./sops + ./editor/neovim + ./programs/firefox + ./programs/tmux + ./programs/dunst + ./programs/kitty + ./programs/rofi + ./programs/obs-studio + ./programs/vscode + ./scripts + ./zsh + ./packages + ./hyprland + ./ssh + ./services/backup-home.nix + ./services/ghettoptt.nix + ]; + firefox.enable = true; + tmux.enable = true; + hyprland.enable = true; + home = { + username = "${user}"; + homeDirectory = "/home/${user}"; + stateVersion = "23.11"; + }; + programs.home-manager.enable = true; + }; }; } diff --git a/home/programs/dunst/default.nix b/home/programs/dunst/default.nix index 2cc72e9..7d3fb84 100644 --- a/home/programs/dunst/default.nix +++ b/home/programs/dunst/default.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: { services.dunst = { @@ -36,7 +41,7 @@ corner_radius = 10; # follow = "mouse"; font = "Source Sans Pro 10"; - format = "%s\\n%b"; #format = "%s %p\n%b" + format = "%s\\n%b"; # format = "%s %p\n%b" frame_color = "#232323"; frame_width = 1; offset = "15x15"; @@ -57,7 +62,9 @@ browser = "/usr/bin/env firefox -new-tab"; }; - fullscreen_delay_everything = { fullscreen = "delay"; }; + fullscreen_delay_everything = { + fullscreen = "delay"; + }; urgency_critical = { background = "#d64e4e"; diff --git a/home/programs/firefox/default.nix b/home/programs/firefox/default.nix index e6d3445..b8675c6 100644 --- a/home/programs/firefox/default.nix +++ b/home/programs/firefox/default.nix @@ -1,6 +1,17 @@ -{ pkgs, config, lib, inputs, user, ... }: { +{ + pkgs, + config, + lib, + inputs, + user, + ... +}: +{ options.firefox.enable = lib.mkEnableOption "Firefox"; - config = - lib.mkIf config.firefox.enable { programs.firefox = { enable = true; }; }; + config = lib.mkIf config.firefox.enable { + programs.firefox = { + enable = true; + }; + }; } diff --git a/home/programs/kitty/default.nix b/home/programs/kitty/default.nix index 754cf45..534c22d 100644 --- a/home/programs/kitty/default.nix +++ b/home/programs/kitty/default.nix @@ -1,24 +1,27 @@ -{ config, pkgs, ... }: { +{ config, pkgs, ... }: +{ xdg.configFile."kitty/kitty.conf" = { source = config.lib.file.mkOutOfStoreSymlink ./. + "/kitty.conf"; target = "kitty/kitty.conf"; }; xdg.configFile."kitty/themes/macchiato.conf" = { - source = pkgs.fetchFromGitHub - { + source = + pkgs.fetchFromGitHub { owner = "catppuccin"; repo = "kitty"; rev = "d7d61716a83cd135344cbb353af9d197c5d7cec1"; sha256 = "mRFa+40fuJCUrR1o4zMi7AlgjRtFmii4fNsQyD8hIjM="; - } + "/themes/macchiato.conf"; + } + + "/themes/macchiato.conf"; }; xdg.configFile."kitty/themes/latte.conf" = { - source = pkgs.fetchFromGitHub - { + source = + pkgs.fetchFromGitHub { owner = "catppuccin"; repo = "kitty"; rev = "d7d61716a83cd135344cbb353af9d197c5d7cec1"; sha256 = "mRFa+40fuJCUrR1o4zMi7AlgjRtFmii4fNsQyD8hIjM="; - } + "/themes/latte.conf"; + } + + "/themes/latte.conf"; }; } diff --git a/home/programs/obs-studio/default.nix b/home/programs/obs-studio/default.nix index 12f0e35..b942f42 100644 --- a/home/programs/obs-studio/default.nix +++ b/home/programs/obs-studio/default.nix @@ -1,40 +1,46 @@ -{ pkgs, lib, osConfig, ... }: +{ + pkgs, + lib, + osConfig, + ... +}: let withCuda = osConfig.system.name == "gunter"; - onnxruntime-gpu = (pkgs.onnxruntime.override { - cudaSupport = withCuda; - }).overrideAttrs - (old: { - # TODO: Remove when fixed in nixpkgs - # https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/development/libraries/onnxruntime/default.nix#L154 - buildInputs = old.buildInputs ++ [ pkgs.cudaPackages.nccl ]; - }); + onnxruntime-gpu = (pkgs.onnxruntime.override { cudaSupport = withCuda; }).overrideAttrs (old: { + # TODO: Remove when fixed in nixpkgs + # https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/development/libraries/onnxruntime/default.nix#L154 + buildInputs = old.buildInputs ++ [ pkgs.cudaPackages.nccl ]; + }); - obs-backgrounremoval-gpu = ((pkgs.obs-studio-plugins.obs-backgroundremoval.override { - onnxruntime = onnxruntime-gpu; - }).overrideAttrs (old: { - version = "1.1.14-beta"; - src = pkgs.fetchFromGitHub { - owner = "occ-ai"; - repo = "obs-backgroundremoval"; - rev = "94be8c35fe077be93a6f5ef347a802295a36dddd"; - hash = "sha256-qnxDNeTWQYiRMqT6jNp8GC8ef6aaAAY+OXAak54dVc8="; - }; - cmakeFlags = - if withCuda then - (lib.lists.remove "-DDISABLE_ONNXRUNTIME_GPU=ON" old.cmakeFlags) - else old.cmakeFlags; - })); + obs-backgrounremoval-gpu = ( + (pkgs.obs-studio-plugins.obs-backgroundremoval.override { onnxruntime = onnxruntime-gpu; }) + .overrideAttrs + (old: { + version = "1.1.14-beta"; + src = pkgs.fetchFromGitHub { + owner = "occ-ai"; + repo = "obs-backgroundremoval"; + rev = "94be8c35fe077be93a6f5ef347a802295a36dddd"; + hash = "sha256-qnxDNeTWQYiRMqT6jNp8GC8ef6aaAAY+OXAak54dVc8="; + }; + cmakeFlags = + if withCuda then + (lib.lists.remove "-DDISABLE_ONNXRUNTIME_GPU=ON" old.cmakeFlags) + else + old.cmakeFlags; + }) + ); in { programs.obs-studio = { enable = true; - plugins = with pkgs.obs-studio-plugins; [ - obs-pipewire-audio-capture - obs-shaderfilter - ] ++ lib.optionals withCuda [ - obs-backgrounremoval-gpu - ]; + plugins = + with pkgs.obs-studio-plugins; + [ + obs-pipewire-audio-capture + obs-shaderfilter + ] + ++ lib.optionals withCuda [ obs-backgrounremoval-gpu ]; }; } diff --git a/home/programs/pywal/default.nix b/home/programs/pywal/default.nix index 1baac39..6c094a8 100644 --- a/home/programs/pywal/default.nix +++ b/home/programs/pywal/default.nix @@ -1,26 +1,28 @@ -{ config, pkgs, ... }: { +{ config, pkgs, ... }: +{ programs.pywal.enable = true; xdg.configFile = { "wal/templates/colors-hyprland.conf" = { - text = ''$foreground = 0xff{foreground.strip} -$background = 0xff{background.strip} -$color0 = 0xff{color0.strip} -$color1 = 0xff{color1.strip} -$color2 = 0xff{color2.strip} -$color3 = 0xff{color3.strip} -$color4 = 0xff{color4.strip} -$color5 = 0xff{color5.strip} -$color6 = 0xff{color6.strip} -$color7 = 0xff{color7.strip} -$color8 = 0xff{color8.strip} -$color9 = 0xff{color9.strip} -$color10 = 0xff{color10.strip} -$color11 = 0xff{color11.strip} -$color12 = 0xff{color12.strip} -$color13 = 0xff{color13.strip} -$color14 = 0xff{color14.strip} -$color15 = 0xff{color15.strip} + text = '' + $foreground = 0xff{foreground.strip} + $background = 0xff{background.strip} + $color0 = 0xff{color0.strip} + $color1 = 0xff{color1.strip} + $color2 = 0xff{color2.strip} + $color3 = 0xff{color3.strip} + $color4 = 0xff{color4.strip} + $color5 = 0xff{color5.strip} + $color6 = 0xff{color6.strip} + $color7 = 0xff{color7.strip} + $color8 = 0xff{color8.strip} + $color9 = 0xff{color9.strip} + $color10 = 0xff{color10.strip} + $color11 = 0xff{color11.strip} + $color12 = 0xff{color12.strip} + $color13 = 0xff{color13.strip} + $color14 = 0xff{color14.strip} + $color15 = 0xff{color15.strip} ''; }; }; diff --git a/home/programs/rofi/default.nix b/home/programs/rofi/default.nix index 33860c3..b463f3c 100644 --- a/home/programs/rofi/default.nix +++ b/home/programs/rofi/default.nix @@ -1,24 +1,27 @@ -{ config, pkgs, ... }: { +{ config, pkgs, ... }: +{ xdg.configFile."rofi/config.rasi" = { source = ./config.rasi; }; xdg.configFile."rofi/macchiato.rasi" = { - source = pkgs.fetchFromGitHub - { + source = + pkgs.fetchFromGitHub { owner = "catppuccin"; repo = "rofi"; rev = "5350da41a11814f950c3354f090b90d4674a95ce"; sha256 = "DNorfyl3C4RBclF2KDgwvQQwixpTwSRu7fIvihPN8JY="; - } + "/basic/.local/share/rofi/themes/catppuccin-macchiato.rasi"; + } + + "/basic/.local/share/rofi/themes/catppuccin-macchiato.rasi"; }; xdg.configFile."rofi/latte.rasi" = { - source = pkgs.fetchFromGitHub - { + source = + pkgs.fetchFromGitHub { owner = "catppuccin"; repo = "rofi"; rev = "5350da41a11814f950c3354f090b90d4674a95ce"; sha256 = "DNorfyl3C4RBclF2KDgwvQQwixpTwSRu7fIvihPN8JY="; - } + "/basic/.local/share/rofi/themes/catppuccin-latte.rasi"; + } + + "/basic/.local/share/rofi/themes/catppuccin-latte.rasi"; }; } diff --git a/home/programs/tmux/default.nix b/home/programs/tmux/default.nix index fdb2647..060d536 100644 --- a/home/programs/tmux/default.nix +++ b/home/programs/tmux/default.nix @@ -1,7 +1,14 @@ -{ pkgs, lib, config, ... }: +{ + pkgs, + lib, + config, + ... +}: with lib; -let cfg = config.tmux.enable; -in { +let + cfg = config.tmux.enable; +in +{ options.tmux.enable = mkEnableOption "tmux"; config = mkIf cfg { programs.tmux = { diff --git a/home/programs/vscode/default.nix b/home/programs/vscode/default.nix index 276d916..91556aa 100644 --- a/home/programs/vscode/default.nix +++ b/home/programs/vscode/default.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ programs.vscode = { enable = true; enableUpdateCheck = true; diff --git a/home/programs/zellij/default.nix b/home/programs/zellij/default.nix index ff00b6e..60ef0a7 100644 --- a/home/programs/zellij/default.nix +++ b/home/programs/zellij/default.nix @@ -1,4 +1,5 @@ -{ ... }: { +{ ... }: +{ programs.zellij = { enable = true; # enableZshIntegration = true; diff --git a/home/scripts/batlvl.nix b/home/scripts/batlvl.nix index c92b5e2..b0a45b6 100644 --- a/home/scripts/batlvl.nix +++ b/home/scripts/batlvl.nix @@ -2,13 +2,10 @@ let batlvl = pkgs.writeShellApplication { name = "batlvl"; - runtimeInputs = [ - ]; + runtimeInputs = [ ]; text = builtins.readFile ./batlvl.sh; }; in { - home.packages = [ - batlvl - ]; + home.packages = [ batlvl ]; } diff --git a/home/scripts/default.nix b/home/scripts/default.nix index e9f26c4..0a97f32 100644 --- a/home/scripts/default.nix +++ b/home/scripts/default.nix @@ -1,7 +1,6 @@ -{ pkgs, config, ... }: { - imports = [ - ./lockhelper.nix - ]; +{ pkgs, config, ... }: +{ + imports = [ ./lockhelper.nix ]; home.file.".local/bin/hl-no-opacity" = { source = ./hl-no-opacity.sh; executable = true; diff --git a/home/scripts/lockhelper.nix b/home/scripts/lockhelper.nix index 7b51fc4..a2cf83d 100644 --- a/home/scripts/lockhelper.nix +++ b/home/scripts/lockhelper.nix @@ -10,7 +10,5 @@ let }; in { - home.packages = [ - lockhelper - ]; + home.packages = [ lockhelper ]; } diff --git a/home/services/backup-home.nix b/home/services/backup-home.nix index aa495f2..70e4c30 100644 --- a/home/services/backup-home.nix +++ b/home/services/backup-home.nix @@ -95,7 +95,10 @@ in systemd.user.services.backup-home = { Unit = { Description = "Backup home directory"; - After = [ "network.target" "sops-nix.service" ]; + After = [ + "network.target" + "sops-nix.service" + ]; }; Service = { Type = "oneshot"; @@ -112,7 +115,10 @@ in Persistent = true; }; Install = { - WantedBy = [ "timers.target" "graphical-session.target" ]; + WantedBy = [ + "timers.target" + "graphical-session.target" + ]; }; }; } diff --git a/home/sops/default.nix b/home/sops/default.nix index 451ba1f..1f4b6d6 100644 --- a/home/sops/default.nix +++ b/home/sops/default.nix @@ -1,4 +1,5 @@ -{ user, ... }: { +{ user, ... }: +{ sops = { age.keyFile = "/home/${user}/.config/sops/age/keys.txt"; defaultSopsFile = ../../secrets/torjus/secret.yaml; diff --git a/home/ssh/gunter.nix b/home/ssh/gunter.nix index 2bf5a3a..71736d1 100644 --- a/home/ssh/gunter.nix +++ b/home/ssh/gunter.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ programs.ssh = { enable = true; controlMaster = "auto"; diff --git a/home/zsh/default.nix b/home/zsh/default.nix index 43e325d..19aa28a 100644 --- a/home/zsh/default.nix +++ b/home/zsh/default.nix @@ -1,4 +1,5 @@ -{ user, pkgs, ... }: { +{ user, pkgs, ... }: +{ home.packages = with pkgs; [ fd ]; programs.direnv = { enable = true; @@ -38,8 +39,14 @@ zplug = { enable = true; plugins = [ - ({ name = "plugins/git"; tags = [ "from:oh-my-zsh" ]; }) - ({ name = "modules/prompt"; tags = [ "from:prezto" ]; }) + ({ + name = "plugins/git"; + tags = [ "from:oh-my-zsh" ]; + }) + ({ + name = "modules/prompt"; + tags = [ "from:prezto" ]; + }) ]; }; }; diff --git a/hosts/gunter/configuration.nix b/hosts/gunter/configuration.nix index aa9e062..a83cf86 100644 --- a/hosts/gunter/configuration.nix +++ b/hosts/gunter/configuration.nix @@ -1,4 +1,10 @@ -{ config, lib, inputs, pkgs, ... }: +{ + config, + lib, + inputs, + pkgs, + ... +}: { imports = [ @@ -35,7 +41,9 @@ enable = true; configurationLimit = 10; }; - loader.efi = { canTouchEfiVariables = true; }; + loader.efi = { + canTouchEfiVariables = true; + }; supportedFilesystems = [ "nfs" ]; }; @@ -112,19 +120,26 @@ xdg.portal = { enable = true; xdgOpenUsePortal = true; - extraPortals = (with pkgs; [ - # unstable.xdg-desktop-portal-hyprland - xdg-desktop-portal-gtk - ]); + extraPortals = ( + with pkgs; + [ + # unstable.xdg-desktop-portal-hyprland + xdg-desktop-portal-gtk + ] + ); }; # Enable flakes nix.settings = { - experimental-features = [ "nix-command" "flakes" ]; - trusted-users = [ "root" "torjus" ]; - substituters = [ - "https://cuda-maintainers.cachix.org" + experimental-features = [ + "nix-command" + "flakes" ]; + trusted-users = [ + "root" + "torjus" + ]; + substituters = [ "https://cuda-maintainers.cachix.org" ]; trusted-public-keys = [ "cuda-maintainers.cachix.org-1:0dq3bujKpuEPMCX6U4WylrUDZ9JyUG0VpVZa7CNfq5E=" ]; diff --git a/hosts/gunter/default.nix b/hosts/gunter/default.nix index b6ab5b2..1d533b6 100644 --- a/hosts/gunter/default.nix +++ b/hosts/gunter/default.nix @@ -1,4 +1,10 @@ -{ inputs, self, pks, ... }: { +{ + inputs, + self, + pks, + ... +}: +{ imports = [ ./configuration.nix ./hardware-configuration.nix diff --git a/hosts/gunter/hardware-configuration.nix b/hosts/gunter/hardware-configuration.nix index 4af6aa2..b34b3ae 100644 --- a/hosts/gunter/hardware-configuration.nix +++ b/hosts/gunter/hardware-configuration.nix @@ -1,37 +1,45 @@ # Do not modify this file! It was generated by ‘nixos-generate-config’ # and may be overwritten by future invocations. Please make changes # to /etc/nixos/configuration.nix instead. -{ config, lib, pkgs, modulesPath, ... }: +{ + config, + lib, + pkgs, + modulesPath, + ... +}: { - imports = - [ - (modulesPath + "/installer/scan/not-detected.nix") - ]; + imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; - boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ]; - boot.initrd.kernelModules = [ ]; - boot.kernelModules = [ "kvm-amd" "v4l2loopback" ]; - boot.extraModulePackages = with config.boot.kernelPackages; [ - v4l2loopback + boot.initrd.availableKernelModules = [ + "nvme" + "xhci_pci" + "ahci" + "usbhid" + "usb_storage" + "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ + "kvm-amd" + "v4l2loopback" + ]; + boot.extraModulePackages = with config.boot.kernelPackages; [ v4l2loopback ]; - fileSystems."/" = - { - device = "/dev/disk/by-uuid/a7d4b697-fffa-4bcb-9dd7-cbbd6121a50c"; - fsType = "xfs"; - }; + fileSystems."/" = { + device = "/dev/disk/by-uuid/a7d4b697-fffa-4bcb-9dd7-cbbd6121a50c"; + fsType = "xfs"; + }; boot.initrd.luks.devices."root".device = "/dev/disk/by-uuid/be82b184-3cc7-483b-9069-f7797f51c853"; - fileSystems."/boot" = - { - device = "/dev/disk/by-uuid/DC0C-AAB3"; - fsType = "vfat"; - }; + fileSystems."/boot" = { + device = "/dev/disk/by-uuid/DC0C-AAB3"; + fsType = "vfat"; + }; - swapDevices = - [{ device = "/dev/disk/by-uuid/2284e9c6-c168-4d4f-ba6a-d270f1ae245d"; }]; + swapDevices = [ { device = "/dev/disk/by-uuid/2284e9c6-c168-4d4f-ba6a-d270f1ae245d"; } ]; # Enables DHCP on each ethernet and wireless interface. In case of scripted networking # (the default) this is the recommended approach. When using systemd-networkd it's diff --git a/hosts/gunter/nfs.nix b/hosts/gunter/nfs.nix index 933603e..3e76512 100644 --- a/hosts/gunter/nfs.nix +++ b/hosts/gunter/nfs.nix @@ -1,22 +1,25 @@ -{ pkgs, ... }: { - environment.systemPackages = with pkgs; [ - nfs-utils - ]; +{ pkgs, ... }: +{ + environment.systemPackages = with pkgs; [ nfs-utils ]; services.rpcbind.enable = true; - systemd.mounts = [{ - type = "nfs"; - mountConfig = { - Options = "rw,soft,noatime"; - }; - what = "nas.home.2rjus.net:/mnt/hdd-pool/media"; - where = "/mnt/nas/media"; - }]; + systemd.mounts = [ + { + type = "nfs"; + mountConfig = { + Options = "rw,soft,noatime"; + }; + what = "nas.home.2rjus.net:/mnt/hdd-pool/media"; + where = "/mnt/nas/media"; + } + ]; - systemd.automounts = [{ - wantedBy = [ "multi-user.target" ]; - automountConfig = { - TimeoutIdleSec = "5min"; - }; - where = "/mnt/nas/media"; - }]; + systemd.automounts = [ + { + wantedBy = [ "multi-user.target" ]; + automountConfig = { + TimeoutIdleSec = "5min"; + }; + where = "/mnt/nas/media"; + } + ]; } diff --git a/hosts/gunter/ollama.nix b/hosts/gunter/ollama.nix index 857eb76..25e6ecd 100644 --- a/hosts/gunter/ollama.nix +++ b/hosts/gunter/ollama.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ services.ollama = { enable = true; acceleration = "cuda"; diff --git a/hosts/gunter/steamuser.nix b/hosts/gunter/steamuser.nix index 932aaa9..1bb8b43 100644 --- a/hosts/gunter/steamuser.nix +++ b/hosts/gunter/steamuser.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ environment.shells = with pkgs; [ zsh ]; services.xserver.desktopManager.xfce.enable = true; diff --git a/hosts/gunter/streamdeck.nix b/hosts/gunter/streamdeck.nix index cf299fa..45a03c5 100644 --- a/hosts/gunter/streamdeck.nix +++ b/hosts/gunter/streamdeck.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ programs.streamdeck-ui = { enable = true; }; diff --git a/hosts/magicman/configuration.nix b/hosts/magicman/configuration.nix index 334f4e0..472c8dc 100644 --- a/hosts/magicman/configuration.nix +++ b/hosts/magicman/configuration.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: { imports = [ ./hardware-configuration.nix ]; @@ -19,14 +24,14 @@ enable = true; configurationLimit = 3; }; - boot.loader.efi = { canTouchEfiVariables = true; }; + boot.loader.efi = { + canTouchEfiVariables = true; + }; boot.initrd.systemd.enable = true; boot.plymouth = { enable = true; - themePackages = with pkgs; [ - catppuccin-plymouth - ]; + themePackages = with pkgs; [ catppuccin-plymouth ]; theme = "catppuccin-macchiato"; extraConfig = '' UseFirmwareBackground=false @@ -62,11 +67,15 @@ "bluez5.enable-sbc-xq" = true; "bluez5.enable-msbc" = true; "bluez5.enable-hw-volume" = true; - "bluez5.roles" = [ "hsp_hs" "hsp_ag" "hfp_hf" "hfp_ag" ]; + "bluez5.roles" = [ + "hsp_hs" + "hsp_ag" + "hfp_hf" + "hfp_ag" + ]; }; }; - # Setup hyprland services.xserver.enable = true; services.xserver.displayManager = { @@ -102,17 +111,26 @@ xdg.portal = { enable = true; xdgOpenUsePortal = true; - extraPortals = (with pkgs; [ - # xdg-desktop-portal-hyprland - xdg-desktop-portal-gtk - ]); + extraPortals = ( + with pkgs; + [ + # xdg-desktop-portal-hyprland + xdg-desktop-portal-gtk + ] + ); }; programs.steam.enable = true; # Enable flakes - nix.settings.experimental-features = [ "nix-command" "flakes" ]; - nix.settings.trusted-users = [ "root" "torjus" ]; + nix.settings.experimental-features = [ + "nix-command" + "flakes" + ]; + nix.settings.trusted-users = [ + "root" + "torjus" + ]; nixpkgs.config.allowUnfree = true; # Install system-wide packages diff --git a/hosts/magicman/default.nix b/hosts/magicman/default.nix index bf2fb9e..fbcdefc 100644 --- a/hosts/magicman/default.nix +++ b/hosts/magicman/default.nix @@ -1,4 +1,10 @@ -{ inputs, self, pks, ... }: { +{ + inputs, + self, + pks, + ... +}: +{ imports = [ ./configuration.nix ./hardware-configuration.nix diff --git a/hosts/magicman/hardware-configuration.nix b/hosts/magicman/hardware-configuration.nix index fb02bad..7dd919e 100644 --- a/hosts/magicman/hardware-configuration.nix +++ b/hosts/magicman/hardware-configuration.nix @@ -1,35 +1,42 @@ # Do not modify this file! It was generated by ‘nixos-generate-config’ # and may be overwritten by future invocations. Please make changes # to /etc/nixos/configuration.nix instead. -{ config, lib, pkgs, modulesPath, ... }: +{ + config, + lib, + pkgs, + modulesPath, + ... +}: { - imports = - [ - (modulesPath + "/installer/scan/not-detected.nix") - ]; + imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; - boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" "sdhci_pci" ]; + boot.initrd.availableKernelModules = [ + "xhci_pci" + "thunderbolt" + "nvme" + "usb_storage" + "sd_mod" + "sdhci_pci" + ]; boot.initrd.kernelModules = [ "i915" ]; boot.kernelModules = [ "kvm-intel" ]; boot.extraModulePackages = [ ]; - fileSystems."/" = - { - device = "/dev/disk/by-uuid/31b20f4c-24bb-4fd1-9a3e-8ccc19fe3d64"; - fsType = "xfs"; - }; + fileSystems."/" = { + device = "/dev/disk/by-uuid/31b20f4c-24bb-4fd1-9a3e-8ccc19fe3d64"; + fsType = "xfs"; + }; boot.initrd.luks.devices."root".device = "/dev/disk/by-uuid/4bbadd2c-94dd-4d80-94bf-9332d24b57bd"; - fileSystems."/boot" = - { - device = "/dev/disk/by-uuid/7FF3-B061"; - fsType = "vfat"; - }; + fileSystems."/boot" = { + device = "/dev/disk/by-uuid/7FF3-B061"; + fsType = "vfat"; + }; - swapDevices = - [{ device = "/dev/disk/by-uuid/6f2c4906-ad88-4d7e-88ec-61cdda41ce28"; }]; + swapDevices = [ { device = "/dev/disk/by-uuid/6f2c4906-ad88-4d7e-88ec-61cdda41ce28"; } ]; # Enables DHCP on each ethernet and wireless interface. In case of scripted networking # (the default) this is the recommended approach. When using systemd-networkd it's diff --git a/hosts/prismo/configuration.nix b/hosts/prismo/configuration.nix index 6123ddc..3a3f2fc 100644 --- a/hosts/prismo/configuration.nix +++ b/hosts/prismo/configuration.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: { imports = [ ./hardware-configuration.nix ]; @@ -9,7 +14,6 @@ sops.age.generateKey = true; sops.secrets."gotify_tokens/backup-home" = { }; - # Bootloader stuff boot.kernelParams = [ "quiet" @@ -20,7 +24,9 @@ enable = true; configurationLimit = 10; }; - boot.loader.efi = { canTouchEfiVariables = true; }; + boot.loader.efi = { + canTouchEfiVariables = true; + }; # Networking stuff networking.hostName = "prismo"; # Define your hostname. @@ -65,14 +71,20 @@ xdg.portal = { enable = true; xdgOpenUsePortal = true; - extraPortals = (with pkgs; [ - xdg-desktop-portal-hyprland - xdg-desktop-portal-gtk - ]); + extraPortals = ( + with pkgs; + [ + xdg-desktop-portal-hyprland + xdg-desktop-portal-gtk + ] + ); }; # Enable flakes - nix.settings.experimental-features = [ "nix-command" "flakes" ]; + nix.settings.experimental-features = [ + "nix-command" + "flakes" + ]; nixpkgs.config.allowUnfree = true; # Install system-wide packages diff --git a/hosts/prismo/default.nix b/hosts/prismo/default.nix index f39e696..81a4363 100644 --- a/hosts/prismo/default.nix +++ b/hosts/prismo/default.nix @@ -1,4 +1,10 @@ -{ inputs, self, pks, ... }: { +{ + inputs, + self, + pks, + ... +}: +{ imports = [ ./configuration.nix ./hardware-configuration.nix diff --git a/hosts/prismo/hardware-configuration.nix b/hosts/prismo/hardware-configuration.nix index fa596b4..f5618df 100644 --- a/hosts/prismo/hardware-configuration.nix +++ b/hosts/prismo/hardware-configuration.nix @@ -1,19 +1,29 @@ # Do not modify this file! It was generated by ‘nixos-generate-config’ # and may be overwritten by future invocations. Please make changes # to /etc/nixos/configuration.nix instead. -{ config, lib, pkgs, modulesPath, ... }: +{ + config, + lib, + pkgs, + modulesPath, + ... +}: { imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; boot = { initrd = { - availableKernelModules = - [ "xhci_pci" "ahci" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ]; + availableKernelModules = [ + "xhci_pci" + "ahci" + "usb_storage" + "sd_mod" + "rtsx_pci_sdmmc" + ]; kernelModules = [ ]; - luks.devices."cryptroot".device = - "/dev/disk/by-uuid/f71b0ace-f38f-435f-a07a-007f9cfe4919"; + luks.devices."cryptroot".device = "/dev/disk/by-uuid/f71b0ace-f38f-435f-a07a-007f9cfe4919"; }; kernelModules = [ "kvm-intel" ]; extraModulePackages = [ ]; @@ -29,8 +39,7 @@ fsType = "vfat"; }; - swapDevices = - [{ device = "/dev/disk/by-uuid/67da36a8-69df-4541-88cd-cba7cbc40b4c"; }]; + swapDevices = [ { device = "/dev/disk/by-uuid/67da36a8-69df-4541-88cd-cba7cbc40b4c"; } ]; # Enables DHCP on each ethernet and wireless interface. In case of scripted networking # (the default) this is the recommended approach. When using systemd-networkd it's @@ -41,6 +50,5 @@ # networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - hardware.cpu.intel.updateMicrocode = - lib.mkDefault config.hardware.enableRedistributableFirmware; + hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; } diff --git a/packages/open-pomodoro.nix b/packages/open-pomodoro.nix index b2079d3..1c282de 100644 --- a/packages/open-pomodoro.nix +++ b/packages/open-pomodoro.nix @@ -1,4 +1,9 @@ -{ lib, buildGoModule, fetchFromGitHub, installShellFiles }: +{ + lib, + buildGoModule, + fetchFromGitHub, + installShellFiles, +}: buildGoModule rec { pname = "openpomodoro-cli"; @@ -13,7 +18,10 @@ buildGoModule rec { vendorHash = "sha256-BR9d/PMQ1ZUYWSDO5ID2bkTN+A+VbaLTlz5t0vbkO60="; - ldflags = [ "-s" "-w" ]; + ldflags = [ + "-s" + "-w" + ]; GOWORK = "off"; diff --git a/system/fonts.nix b/system/fonts.nix index c6a0c0b..597b887 100644 --- a/system/fonts.nix +++ b/system/fonts.nix @@ -1,10 +1,18 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ environment.systemPackages = with pkgs; [ twemoji-color-font ]; fonts.packages = with pkgs; [ fira-code fira-code-symbols font-awesome - (nerdfonts.override { fonts = [ "JetBrainsMono" "FiraCode" "DroidSansMono" "DejaVuSansMono" ]; }) + (nerdfonts.override { + fonts = [ + "JetBrainsMono" + "FiraCode" + "DroidSansMono" + "DejaVuSansMono" + ]; + }) noto-fonts noto-fonts-cjk noto-fonts-emoji diff --git a/system/fwupd.nix b/system/fwupd.nix index 712b81a..db29fba 100644 --- a/system/fwupd.nix +++ b/system/fwupd.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ services.fwupd = { enable = true; }; diff --git a/system/monitoring.nix b/system/monitoring.nix index 312489e..9041edc 100644 --- a/system/monitoring.nix +++ b/system/monitoring.nix @@ -29,5 +29,9 @@ wantedBy = [ "multi-user.target" ]; }; - networking.firewall.allowedTCPPorts = [ 9100 9558 8989 ]; + networking.firewall.allowedTCPPorts = [ + 9100 + 9558 + 8989 + ]; } diff --git a/system/security.nix b/system/security.nix index 700fa27..0cbdf01 100644 --- a/system/security.nix +++ b/system/security.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ # Enable sudo security.sudo = { enable = true; diff --git a/system/services.nix b/system/services.nix index 25a79a4..228eae4 100644 --- a/system/services.nix +++ b/system/services.nix @@ -1,4 +1,5 @@ -{ pkgs, ... }: { +{ pkgs, ... }: +{ services = { dbus.enable = true; pipewire = { diff --git a/system/users.nix b/system/users.nix index ed555be..bf97e8e 100644 --- a/system/users.nix +++ b/system/users.nix @@ -21,7 +21,6 @@ "libvirtd" ]; # Install some user packages - packages = with pkgs; [ - ]; + packages = with pkgs; [ ]; }; }