Personal Nix flake
nixos home-manager nix
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

chore: Merge branch 'develop'

+127 -99
-31
nix/home/modules/base/default.nix
··· 1 - { 2 - config, 3 - inputs, 4 - lib, 5 - osConfig ? {}, 6 - ... 7 - }: let 8 - inherit (lib) mkDefault; 9 - inherit (inputs.self.lib.config.nix) settings; 10 - cfg = config.my.modules; 11 - in { 12 - options.my.modules.enable = 13 - lib.mkEnableOption "base home config" 14 - // {default = true;}; 15 - config = lib.mkIf cfg.enable { 16 - programs.home-manager.enable = mkDefault true; 17 - nix = 18 - { 19 - inherit settings; 20 - gc = { 21 - automatic = osConfig == {}; 22 - frequency = "daily"; 23 - options = "--delete-older-than 7d"; 24 - }; 25 - } 26 - // (lib.optionalAttrs (osConfig != {}) { 27 - inherit (osConfig.nix) extraOptions; 28 - }); 29 - systemd.user.startServices = "sd-switch"; 30 - }; 31 - }
+1 -3
nix/home/modules/cli/default.nix
··· 6 6 inherit (lib) mkDefault mkEnableOption mkIf; 7 7 cfg = config.my.modules.cli; 8 8 in { 9 - options.my.modules.cli.enable = 10 - mkEnableOption "cli modules" 11 - // {default = true;}; 9 + options.my.modules.cli.enable = mkEnableOption "cli modules"; 12 10 13 11 config.my.modules.cli = mkIf cfg.enable { 14 12 editors.enable = mkDefault true;
+7 -8
nix/home/modules/default.nix
··· 1 1 { 2 2 inputs, 3 3 lib, 4 - osConfig ? {}, 5 - pkgs, 6 4 ... 7 5 }: let 8 6 inherit (inputs) self; 9 - inherit (inputs.self.lib.config) nix; 10 7 inherit (inputs.self.lib.loaders) listDefault; 8 + inherit (lib) mkDefault; 11 9 in { 12 10 imports = 13 11 ["${self}/nix/shared"] ··· 23 21 wayland-pipewire-idle-inhibit.homeModules.default 24 22 ]); 25 23 26 - nix.package = lib.mkForce (osConfig.nix.package or pkgs.nix); 27 - nixpkgs = lib.mkIf (osConfig == {} || !osConfig.home-manager.useGlobalPkgs) { 28 - config = 29 - nix.pkgs.config 30 - // {enableCuda = osConfig.nix.config.enableCuda or false;}; 24 + my.modules = { 25 + cli.enable = mkDefault true; 26 + nix.enable = mkDefault true; 31 27 }; 28 + 29 + programs.home-manager.enable = lib.mkDefault true; 30 + systemd.user.startServices = "sd-switch"; 32 31 }
+33
nix/home/modules/nix/default.nix
··· 1 + { 2 + config, 3 + inputs, 4 + lib, 5 + osConfig ? {}, 6 + pkgs, 7 + ... 8 + }: let 9 + inherit (inputs.self.lib.config) nix; 10 + cfg = config.my.modules.nix; 11 + in { 12 + options.my.modules.nix.enable = lib.mkEnableOption "nix"; 13 + config = lib.mkIf (cfg.enable) { 14 + nix = 15 + { 16 + inherit (nix) settings; 17 + gc = { 18 + automatic = osConfig == {}; 19 + frequency = "daily"; 20 + options = "--delete-older-than 7d"; 21 + }; 22 + package = lib.mkForce (osConfig.nix.package or pkgs.nix); 23 + } 24 + // (lib.optionalAttrs (osConfig != {}) { 25 + inherit (osConfig.nix) extraOptions; 26 + }); 27 + nixpkgs = lib.mkIf (osConfig == {} || !osConfig.home-manager.useGlobalPkgs) { 28 + config = 29 + nix.pkgs.config 30 + // {enableCuda = osConfig.nix.config.enableCuda or false;}; 31 + }; 32 + }; 33 + }
-1
nix/home/modules/profiles/work.nix
··· 40 40 ''; 41 41 42 42 my.modules = { 43 - enable = true; 44 43 cli.enable = true; 45 44 cli.git.enable = true; 46 45 cli.hishtory.enable = false;
-43
nix/nixos/modules/base/default.nix
··· 1 - { 2 - lib, 3 - pkgs, 4 - ... 5 - }: { 6 - options.my.modules.enable = 7 - lib.mkEnableOption "base nixos config" 8 - // {default = true;}; 9 - config = { 10 - environment.systemPackages = with pkgs; [ 11 - android-udev-rules 12 - helix 13 - sbctl 14 - vim 15 - wget 16 - ]; 17 - environment.sessionVariables = { 18 - NIXPKGS_ALLOW_UNFREE = "1"; 19 - }; 20 - 21 - home-manager = { 22 - backupFileExtension = "backup"; 23 - useGlobalPkgs = true; 24 - useUserPackages = true; 25 - }; 26 - stylix = { 27 - homeManagerIntegration = { 28 - autoImport = false; 29 - followSystem = true; 30 - }; 31 - targets.plymouth.enable = false; 32 - }; 33 - systemd = { 34 - targets.network-online.wantedBy = pkgs.lib.mkForce []; 35 - services.NetworkManager-wait-online.wantedBy = pkgs.lib.mkForce []; 36 - }; 37 - zramSwap = { 38 - enable = true; 39 - algorithm = "zstd"; 40 - memoryPercent = 50; 41 - }; 42 - }; 43 - }
+23 -11
nix/nixos/modules/default.nix
··· 2 2 config, 3 3 inputs, 4 4 lib, 5 + pkgs, 5 6 ... 6 7 }: let 7 8 inherit (inputs) self; 8 - inherit (inputs.self.lib) isNvidia; 9 - inherit (inputs.self.lib.config) nix; 10 9 inherit (inputs.self.lib.loaders) listDefault; 11 10 inherit (lib) mkDefault; 12 11 in { ··· 32 31 kernel = mkDefault true; 33 32 users = mkDefault true; 34 33 }; 34 + my.modules = { 35 + nix.enable = mkDefault true; 36 + theming.enable = mkDefault true; 37 + zram.enable = mkDefault true; 38 + }; 39 + my.networking.tailscale.enable = mkDefault true; 40 + my.security.enable = mkDefault true; 35 41 36 - nix.gc = { 37 - automatic = let 38 - nhCfg = config.programs.nh; 39 - in 40 - !nhCfg.enable || !nhCfg.clean.enable; 41 - dates = "weekly"; 42 + environment.systemPackages = with pkgs; [ 43 + android-udev-rules 44 + helix 45 + sbctl 46 + vim 47 + wget 48 + ]; 49 + home-manager = { 50 + backupFileExtension = "backup"; 51 + useGlobalPkgs = true; 52 + useUserPackages = true; 42 53 }; 43 - nixpkgs.config = 44 - nix.pkgs.config 45 - // {enableCuda = isNvidia config;}; 54 + systemd = { 55 + targets.network-online.wantedBy = pkgs.lib.mkForce []; 56 + services.NetworkManager-wait-online.wantedBy = pkgs.lib.mkForce []; 57 + }; 46 58 }
+27
nix/nixos/modules/nix/default.nix
··· 1 + { 2 + config, 3 + inputs, 4 + lib, 5 + ... 6 + }: let 7 + inherit (inputs.self.lib) isNvidia; 8 + inherit (inputs.self.lib.config) nix; 9 + cfg = config.my.modules.nix; 10 + in { 11 + options.my.modules.nix.enable = lib.mkEnableOption "nix"; 12 + config = lib.mkIf (cfg.enable) { 13 + environment.sessionVariables = { 14 + NIXPKGS_ALLOW_UNFREE = "1"; 15 + }; 16 + nix.gc = { 17 + automatic = let 18 + nhCfg = config.programs.nh; 19 + in 20 + !nhCfg.enable || !nhCfg.clean.enable; 21 + dates = "weekly"; 22 + }; 23 + nixpkgs.config = 24 + nix.pkgs.config 25 + // {enableCuda = isNvidia config;}; 26 + }; 27 + }
+1 -1
nix/nixos/modules/security/default.nix
··· 8 8 cfg = config.my.security; 9 9 in { 10 10 options.my.security = { 11 - enable = lib.mkEnableOption "security settings" // {default = true;}; 11 + enable = lib.mkEnableOption "security settings"; 12 12 u2f = { 13 13 control = lib.mkOption { 14 14 inherit (options.security.pam.u2f.control) description type;
+1 -1
nix/nixos/modules/tailscale/default.nix
··· 9 9 cfg = config.my.networking.tailscale; 10 10 in { 11 11 options.my.networking.tailscale = { 12 - enable = lib.mkEnableOption "tailscale" // {default = true;}; 12 + enable = lib.mkEnableOption "tailscale"; 13 13 authKeyParameters = 14 14 options.services.tailscale.authKeyParameters 15 15 // {
+18
nix/nixos/modules/theming/default.nix
··· 1 + { 2 + config, 3 + lib, 4 + ... 5 + }: let 6 + cfg = config.my.modules.theming; 7 + in { 8 + options.my.modules.theming.enable = lib.mkEnableOption "theming"; 9 + config = lib.mkIf (cfg.enable) { 10 + stylix = { 11 + homeManagerIntegration = { 12 + autoImport = false; 13 + followSystem = true; 14 + }; 15 + targets.plymouth.enable = false; 16 + }; 17 + }; 18 + }
+16
nix/nixos/modules/zram/default.nix
··· 1 + { 2 + config, 3 + lib, 4 + ... 5 + }: let 6 + cfg = config.my.modules.zram; 7 + in { 8 + options.my.modules.zram.enable = lib.mkEnableOption "zram"; 9 + config = lib.mkIf (cfg.enable) { 10 + zramSwap = { 11 + enable = true; 12 + algorithm = "zstd"; 13 + memoryPercent = 50; 14 + }; 15 + }; 16 + }