refactor
This commit is contained in:
parent
a992a7b701
commit
b61bb970a5
30 changed files with 69 additions and 34 deletions
16
flake.nix
16
flake.nix
|
|
@ -25,10 +25,9 @@
|
|||
let
|
||||
lib = nixpkgs.lib;
|
||||
lib' = import ./lib.nix { inherit lib; };
|
||||
mod = lib'.walk-dir ./mod;
|
||||
|
||||
specialArgs = {
|
||||
inherit inputs lib' mod;
|
||||
inherit inputs lib';
|
||||
var = (lib'.walk-dir ./var).map_import_with_lib;
|
||||
};
|
||||
overlays = _: {
|
||||
|
|
@ -44,9 +43,8 @@
|
|||
};
|
||||
modules = [
|
||||
./host/solo
|
||||
mod.common.to_mod
|
||||
mod.pc-common.to_mod
|
||||
nixos-config-hidden.nixosModules.pc
|
||||
./host
|
||||
./mod
|
||||
overlays
|
||||
];
|
||||
};
|
||||
|
|
@ -58,9 +56,8 @@
|
|||
};
|
||||
modules = [
|
||||
./host/c2
|
||||
mod.common.to_mod
|
||||
mod.pc-common.to_mod
|
||||
nixos-config-hidden.nixosModules.pc
|
||||
./host
|
||||
./mod
|
||||
overlays
|
||||
];
|
||||
};
|
||||
|
|
@ -80,7 +77,8 @@
|
|||
};
|
||||
imports = [
|
||||
./host/roam
|
||||
mod.common.to_mod
|
||||
./host
|
||||
./mod
|
||||
overlays
|
||||
];
|
||||
};
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@
|
|||
common-cpu-intel
|
||||
common-pc-laptop
|
||||
common-pc-laptop-ssd
|
||||
../../pc
|
||||
];
|
||||
|
||||
boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
||||
|
|
|
|||
10
host/default.nix
Normal file
10
host/default.nix
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./boot.nix
|
||||
./locale.nix
|
||||
./nix.nix
|
||||
./shell.nix
|
||||
./users.nix
|
||||
];
|
||||
}
|
||||
|
|
@ -1,11 +1,14 @@
|
|||
{ lib', ... }:
|
||||
let
|
||||
submodules = lib'.walk-dir ./.;
|
||||
in
|
||||
{
|
||||
networking.hostName = "roam";
|
||||
|
||||
imports = [ submodules.to_mod_without_default ];
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./networking.nix
|
||||
./secruity.nix
|
||||
./services.nix
|
||||
./wireguard.nix
|
||||
];
|
||||
|
||||
# ====== DON'T CHANGE ======
|
||||
system.stateVersion = "24.11";
|
||||
|
|
|
|||
|
|
@ -1,11 +1,13 @@
|
|||
{ lib', ... }:
|
||||
let
|
||||
submodules = lib'.walk-dir ./.;
|
||||
in
|
||||
{ ... }:
|
||||
{
|
||||
networking.hostName = "solo";
|
||||
|
||||
imports = [ submodules.to_mod_without_default ];
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./keyboard.nix
|
||||
./nvidia-gpu.nix
|
||||
../../pc
|
||||
];
|
||||
|
||||
powerManagement = {
|
||||
enable = true;
|
||||
|
|
|
|||
1
mod/default.nix
Normal file
1
mod/default.nix
Normal file
|
|
@ -0,0 +1 @@
|
|||
{ ... }: { }
|
||||
21
pc/default.nix
Normal file
21
pc/default.nix
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
inputs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
./audio.nix
|
||||
./fonts.nix
|
||||
./gpg.nix
|
||||
./home-manager.nix
|
||||
./network.nix
|
||||
./nix.nix
|
||||
./security.nix
|
||||
./services.nix
|
||||
./software
|
||||
./sync.nix
|
||||
inputs.nixos-config-hidden.nixosModules.pc
|
||||
];
|
||||
}
|
||||
|
|
@ -6,6 +6,12 @@
|
|||
...
|
||||
}:
|
||||
{
|
||||
options.home = lib.mkOption {
|
||||
type = lib.types.attrsOf lib.types.str;
|
||||
default = { };
|
||||
description = "home-manager configuration.";
|
||||
};
|
||||
|
||||
imports = [
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
{
|
||||
|
|
@ -20,11 +26,4 @@
|
|||
config = {
|
||||
home.home.stateVersion = config.system.stateVersion;
|
||||
};
|
||||
|
||||
options = {
|
||||
home = lib.mkOption {
|
||||
type = lib.types.attrs;
|
||||
default = { };
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -9,10 +9,6 @@
|
|||
systemd.network.wait-online.enable = false;
|
||||
|
||||
services = {
|
||||
tailscale = {
|
||||
enable = true;
|
||||
useRoutingFeatures = "client";
|
||||
};
|
||||
mullvad-vpn.enable = true;
|
||||
blueman.enable = true;
|
||||
resolved = {
|
||||
|
|
@ -41,10 +37,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
firewall = {
|
||||
allowedUDPPorts = [ 51820 ];
|
||||
};
|
||||
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.macAddress = "random";
|
||||
9
pc/software/default.nix
Normal file
9
pc/software/default.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./development.nix
|
||||
./editors.nix
|
||||
./programs.nix
|
||||
./window-manager.nix
|
||||
];
|
||||
}
|
||||
|
|
@ -2,7 +2,6 @@
|
|||
{
|
||||
home.services.unison = {
|
||||
enable = true;
|
||||
package = pkgs.unison;
|
||||
pairs = {
|
||||
"docs".roots = [
|
||||
"/home/hd/Documents"
|
||||
Loading…
Add table
Add a link
Reference in a new issue