ctucx.git: nixfiles

ctucx' nixfiles

commit 252434d4f93917ea95aef5cb83a94ea2097aba93
parent 34aa2cfd4e82dca432756d7345fb2fd7cc05c771
Author: Leah (ctucx) <leah@ctu.cx>
Date: Mon, 12 Sep 2022 11:54:46 +0200

configuration/common: support both darwin and linux! \o/
28 files changed, 315 insertions(+), 302 deletions(-)
D
configurations/common.nix
|
112
-------------------------------------------------------------------------------
A
configurations/common/darwin.nix
|
35
+++++++++++++++++++++++++++++++++++
A
configurations/common/default.nix
|
69
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
A
configurations/common/linux.nix
|
75
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
M
configurations/darwin/keyboard.nix
|
4
----
D
configurations/darwin/systemEnvironment.nix
|
34
----------------------------------
D
configurations/desktop-sway.nix
|
85
-------------------------------------------------------------------------------
R
configurations/bluetooth.nix -> configurations/linux/bluetooth.nix
|
0
A
configurations/linux/desktop-sway.nix
|
86
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
R
configurations/fonts.nix -> configurations/linux/fonts.nix
|
0
R
configurations/gtk.nix -> configurations/linux/gtk.nix
|
0
R
configurations/mobile-device.nix -> configurations/linux/mobile-device.nix
|
0
R
configurations/qt.nix -> configurations/linux/qt.nix
|
0
R
configurations/sdr.nix -> configurations/linux/sdr.nix
|
0
R
configurations/thunderbolt.nix -> configurations/linux/thunderbolt.nix
|
0
R
configurations/xdg.nix -> configurations/linux/xdg.nix
|
0
M
machines/blechbuechse/darwin-configuration.nix
|
27
+--------------------------
M
machines/blechkasten/darwin-configuration.nix
|
26
+-------------------------
M
machines/coladose/configuration.nix
|
12
++++++------
M
machines/desastro/configuration.nix
|
3
++-
M
machines/hector/configuration.nix
|
3
++-
M
machines/lollo/configuration.nix
|
3
++-
M
machines/osterei/configuration.nix
|
3
++-
M
machines/wanderduene/configuration.nix
|
2
+-
M
modules/default.nix
|
18
+++++++++++++-----
M
pkgs/default.nix
|
9
+++++++++
R
configurations/darwin/nixpkgs-overrides.nix -> pkgs/overlays/darwin.nix
|
0
A
pkgs/overlays/linux.nix
|
11
+++++++++++
diff --git a/configurations/common.nix b/configurations/common.nix
@@ -1,112 +0,0 @@
-{ config, pkgs, lib, ... }:
-
-{
-
-  imports = [
-    <home-manager/nixos>
-    <agenix/modules/age.nix>
-
-    ../pkgs
-    ../modules
-    ../helpers/make-nixpkgs.nix
-
-    ./programs/cli/bash.nix
-    ./programs/cli/git.nix
-    ./programs/cli/micro.nix
-    ./programs/cli/ssh.nix
-    ./programs/cli/tmux.nix
-    ./programs/cli/htop.nix
-    ./programs/cli/utilities.nix
-    ./programs/cli/network-utilities.nix
-    ./programs/cli/scripts.nix
-  ];
-
-  home-manager.useGlobalPkgs = true;
-
-  nix = {
-    trustedUsers      = [ "@wheel" ];
-    extraOptions      = "experimental-features = nix-command";
-    autoOptimiseStore = true;
-    optimise     = {
-      automatic = true;
-      dates     = [ "12:00" "15:00" "18:00" "21:00" ];
-    };
-    gc           = {
-      automatic = true;
-      options   = "--delete-older-than 3d";
-      dates     = "18:00";
-    };
-  };
-
-  i18n.defaultLocale  = "en_US.UTF-8";
-  time.timeZone       = "Europe/Berlin";
-
-  services = {
-    timesyncd.enable = true;
-    vnstat.enable    = true;
-    vnstati.enable   = true;
-    fstrim.enable    = true;
-
-    journald.extraConfig = "SystemMaxUse=1G";
-
-    nginx = {
-      recommendedGzipSettings  = true;
-      recommendedOptimisation  = true;
-      recommendedProxySettings = true;
-      recommendedTlsSettings   = true;
-      appendHttpConfig         = "server_names_hash_bucket_size 64;";
-      virtualHosts.default = {
-        default   = true;
-        rejectSSL = true;
-      };
-    };
-
-    openssh = {
-      enable                 = true;
-      startWhenNeeded        = true;
-      ports                  = [ 22 ];
-      passwordAuthentication = false;
-      permitRootLogin        = "without-password";
-    };
-  };
-
-  security = {
-    acme.acceptTerms    = true;
-    acme.defaults.email = "letsencrypt@ctu.cx";
-  };
-
-  environment.systemPackages = with pkgs; [
-    alacritty.terminfo
-    agenix
- ];
-
-  users.users = {
-
-    root.openssh.authorizedKeys.keys = [
-      "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDb2eZ2ymt+Zsf0eTlmjW2jPdS013lbde1+EGkgu6bz9lVTR8aawshF2HcoaWp5a5dJr3SKyihDM8hbWSYB3qyTHihNGyCArqSvAtZRw301ailRVHGqiwUITTfcg1533TtmWvlJZgOIFM1VvSAfdueDRRRzbygmn749fS9nhUTDzLtjqX5LvhpqhzsD+eOqPrV6Ne8E1e42JxQb5AJPY1gj9mk6eAarvtEHQYEe+/hp9ERjtCdN5DfuOJnqfaKS0ytPj/NbQskbX/TMgeUVio11iC2NbXsnAtzMmtbLX4mxlDQrR6aZmU/rHQ4aeJqI/Tj2rrF46icri7s0tnnit1OjT5PSxXgifcOtn06qoxYZMT1x+Dyrt40vNkGmxmxCnirm8B+6MKXgd/Ys+7tnOm1ht8TmLm96x6KdOiF3Zq/tMxhPAzp8JriTKSo7k7U9XxStFghTbhhBNc7OX89ZbpalLEnvbQiz87gZxhcx8cLvzIjslOHmZOSWC5Pgr4wwuj3Akq63i4ya6/BzM6v4UoBuDAB6fz3NHKL4R5X20la7Pvt7OBysQkGClWfj6ipMR1bFE2mfYtlMioXNgTjC+NCpEl1+81MH7dv2565Hk8CLV8FMxv6GujbAZGjjcM47lpWM1cBQvpBMUA/lLkyiCPK0YxNWAB7Co+jYDl6CR0Ubew== cardno:6445161"
-    ];
-
-    leah = {
-      isNormalUser                  = true;
-      initialPassword               = "foobar123";
-      extraGroups                   = [ "wheel" ]; # Enable ‘sudo’ for the user.
-      openssh.authorizedKeys.keys   = [
-        "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDb2eZ2ymt+Zsf0eTlmjW2jPdS013lbde1+EGkgu6bz9lVTR8aawshF2HcoaWp5a5dJr3SKyihDM8hbWSYB3qyTHihNGyCArqSvAtZRw301ailRVHGqiwUITTfcg1533TtmWvlJZgOIFM1VvSA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B+4Bgi/vqnjY+gqVC+LG8= root@blechkasten"
-      ];
-    };
-
-  };
-
-  home-manager.users.leah = {
-    home = {
-      language = {
-        "base"     = "en_US.UTF-8";
-        "time"     = "de_DE.utf8";
-        "address"  = "de_DE.utf8";
-        "monetary" = "de_DE.utf8";
-        "paper"    = "de_DE.utf8";
-      };
-    };
-  };
-}
diff --git a/configurations/common/darwin.nix b/configurations/common/darwin.nix
@@ -0,0 +1,35 @@
+{ config, pkgs, lib, ... }:
+
+{
+
+  imports = [
+    ../darwin/systemSettings.nix
+    ../darwin/appSettings.nix
+    ../darwin/keyboard.nix
+    ../darwin/trackpad.nix
+    ../darwin/homebrew.nix
+    ../darwin/finder.nix
+    ../darwin/skhd.nix
+    ../darwin/yabai.nix
+    ../darwin/speakers.nix
+  ];
+
+  services.nix-daemon.enable = true;
+
+  home-manager = {
+    useUserPackages = true;
+
+    users.leah.home.packages      = with pkgs; [ bgiparser asitop colmena ];
+    users.leah.home.homeDirectory = lib.mkForce "/Users/leah/";
+  };
+
+  environment = {
+    darwinConfig   = "\$HOME/nixfiles/darwin-configuration.nix";
+    loginShell     = "${pkgs.bashInteractive}/bin/bash";
+    shells         = [ pkgs.bashInteractive ];
+    systemPackages = with pkgs; [
+      bashInteractive
+    ];
+  };
+
+}
diff --git a/configurations/common/default.nix b/configurations/common/default.nix
@@ -0,0 +1,69 @@
+{ config, pkgs, lib, ... }:
+
+{
+
+  imports = (builtins.concatLists [
+    [
+      ../../pkgs
+      ../../modules
+      ../../helpers/make-nixpkgs.nix
+
+      ../programs/cli/bash.nix
+      ../programs/cli/micro.nix
+      ../programs/cli/tmux.nix
+      ../programs/cli/ssh.nix
+      ../programs/cli/git.nix
+      ../programs/cli/htop.nix
+      ../programs/cli/utilities.nix
+      ../programs/cli/network-utilities.nix
+      ../programs/cli/scripts.nix
+    ]
+    (if (builtins.currentSystem == "x86_64-linux") then [
+      <home-manager/nixos>
+      <agenix/modules/age.nix>
+
+      ./linux.nix
+    ] else [])
+    (if (builtins.currentSystem == "aarch64-darwin") then [
+      <home-manager/nix-darwin>
+
+      ./darwin.nix
+
+      ../darwin/systemSettings.nix
+      ../darwin/appSettings.nix
+      ../darwin/keyboard.nix
+      ../darwin/trackpad.nix
+      ../darwin/homebrew.nix
+      ../darwin/finder.nix
+      ../darwin/skhd.nix
+      ../darwin/yabai.nix
+      ../darwin/speakers.nix
+    ] else [])
+  ]);
+
+  time.timeZone       = "Europe/Berlin";
+
+  environment.systemPackages = with pkgs; [
+    alacritty.terminfo
+    agenix
+  ];
+
+  nix = {
+    package = pkgs.nix;
+    extraOptions = ''
+      experimental-features = nix-command
+    '';
+  };
+
+  home-manager.users.leah = {
+    home = {
+      language = {
+        "base"     = "en_US.UTF-8";
+        "time"     = "de_DE.utf8";
+        "address"  = "de_DE.utf8";
+        "monetary" = "de_DE.utf8";
+        "paper"    = "de_DE.utf8";
+      };
+    };
+  };
+}
diff --git a/configurations/common/linux.nix b/configurations/common/linux.nix
@@ -0,0 +1,75 @@
+{ config, lib, pkgs, ... }:
+
+{
+
+  home-manager.useGlobalPkgs = true;
+
+  i18n.defaultLocale  = "en_US.UTF-8";
+
+  nix = {
+    trustedUsers      = [ "@wheel" ];
+    autoOptimiseStore = true;
+    optimise     = {
+      automatic = true;
+      dates     = [ "12:00" "15:00" "18:00" "21:00" ];
+    };
+    gc           = {
+      automatic = true;
+      options   = "--delete-older-than 3d";
+      dates     = "18:00";
+    };
+  };
+
+  services = {
+    timesyncd.enable = true;
+    vnstat.enable    = true;
+    vnstati.enable   = true;
+    fstrim.enable    = true;
+
+    journald.extraConfig = "SystemMaxUse=1G";
+
+    nginx = {
+      recommendedGzipSettings  = true;
+      recommendedOptimisation  = true;
+      recommendedProxySettings = true;
+      recommendedTlsSettings   = true;
+      appendHttpConfig         = "server_names_hash_bucket_size 64;";
+      virtualHosts.default = {
+        default   = true;
+        rejectSSL = true;
+      };
+    };
+
+    openssh = {
+      enable                 = true;
+      startWhenNeeded        = true;
+      ports                  = [ 22 ];
+      passwordAuthentication = false;
+      permitRootLogin        = "without-password";
+    };
+  };
+
+  security = {
+    acme.acceptTerms    = true;
+    acme.defaults.email = "letsencrypt@ctu.cx";
+  };
+
+  users.users = {
+
+    root.openssh.authorizedKeys.keys = [
+      "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDb2eZ2ymt+Zsf0eTlmjW2jPdS013lbde1+EGkgu6bz9lVTR8aawshF2HcoaWp5a5dJr3SKyihDM8hbWSYB3qyTHihNGyCArqSvAtZRw301ailRVHGqiwUITTfcg1533TtmWvlJZgOIFM1VvSAfdueDRRRzbygmn749fS9nhUTDzLtjqX5LvhpqhzsD+eOqPrV6Ne8E1e42JxQb5AJPY1gj9mk6eAarvtEHQYEe+/hp9ERjtCdN5DfuOJnqfaKS0ytPj/NbQskbX/TMgeUVio11iC2NbXsnAtzMmtbLX4mxlDQrR6aZmU/rHQ4aeJqI/Tj2rrF46icri7s0tnnit1OjT5PSxXgifcOtn06qoxYZMT1x+Dyrt40vNkGmxmxCnirm8B+6MKXgd/Ys+7tnOm1ht8TmLm96x6KdOiF3Zq/tMxhPAzp8JriTKSo7k7U9XxStFghTbhhBNc7OX89ZbpalLEnvbQiz87gZxhcx8cLvzIjslOHmZOSWC5Pgr4wwuj3Akq63i4ya6/BzM6v4UoBuDAB6fz3NHKL4R5X20la7Pvt7OBysQkGClWfj6ipMR1bFE2mfYtlMioXNgTjC+NCpEl1+81MH7dv2565Hk8CLV8FMxv6GujbAZGjjcM47lpWM1cBQvpBMUA/lLkyiCPK0YxNWAB7Co+jYDl6CR0Ubew== cardno:6445161"
+    ];
+
+    leah = {
+      isNormalUser                  = true;
+      initialPassword               = "foobar123";
+      extraGroups                   = [ "wheel" ]; # Enable ‘sudo’ for the user.
+      openssh.authorizedKeys.keys   = [
+        "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDb2eZ2ymt+Zsf0eTlmjW2jPdS013lbde1+EGkgu6bz9lVTR8aawshF2HcoaWp5a5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k74z9V5V8NpS5UlXGVWAg3LOgrhUgneHEhfAWEW+6/kMeDazI3IYB5dGMQ2T2lijN5R5Kww2RH24B+4Bgi/vqnjY+gqVC+LG8= root@blechkasten"
+      ];
+    };
+
+  };
+
+}
diff --git a/configurations/darwin/keyboard.nix b/configurations/darwin/keyboard.nix
@@ -2,10 +2,6 @@
 
 {
 
-  imports = [
-    ../../modules/darwin/hidutil.nix
-  ];
-
   system.defaults = {
     NSGlobalDomain = {
       # keyboard repeat rate (default: 25/6)
diff --git a/configurations/darwin/systemEnvironment.nix b/configurations/darwin/systemEnvironment.nix
@@ -1,34 +0,0 @@
-{ config, pkgs, lib, ... }:
-
-{
-
-  imports = [
-    ../../pkgs
-  ];
-
-  nix = {
-    package = pkgs.nix;
-    extraOptions = ''
-      experimental-features = nix-command
-    '';
-  };
-  services.nix-daemon.enable = true;
-
-  home-manager = {
-    useUserPackages = true;
-
-    users.leah.home.packages      = with pkgs; [ bgiparser asitop colmena ];
-    users.leah.home.homeDirectory = lib.mkForce "/Users/leah/";
-  };
-
-  environment = {
-    darwinConfig   = "\$HOME/nixfiles/darwin-configuration.nix";
-    loginShell     = "${pkgs.bashInteractive}/bin/bash";
-    shells         = [ pkgs.bashInteractive ];
-    systemPackages = with pkgs; [
-      bashInteractive
-      agenix
-    ];
-  };
-
-}
diff --git a/configurations/desktop-sway.nix b/configurations/desktop-sway.nix
@@ -1,85 +0,0 @@
-{ config, lib, pkgs, home-manager, ... }:
-
-{
-  nixpkgs.config.allowUnfree = true;
-  environment.noXlibs        = false;
-
-  hardware = {
-    opengl = {
-      enable        = true;
-      driSupport    = true;
-      extraPackages = with pkgs; [
-        vaapiIntel
-        vaapiVdpau
-        libvdpau-va-gl
-        intel-media-driver
-      ];
-    };
-
-    trackpoint = {
-      enable       = true;
-      device       = "TPPS/2 JYT_Synaptics TrackPoint";
-      emulateWheel = true;
-      speed        = 85;
-      sensitivity  = 80;
-    };
-  };
-
-  programs = {
-    dconf.enable = true;
-  };
-
-  services = {
-    nscd.enable         = true;
-    getty.autologinUser = "leah";
-  };
-
-  users.users.leah.extraGroups = [ "dialout" ];
-
-  home-manager.users.leah = {
-    manual.html.enable = true;
-  };
-
-  imports = [
-    ./fonts.nix
-    ./gtk.nix
-    ./qt.nix
-    ./xdg.nix
-
-    ./programs/systemd-lock-handler.nix
-
-    ./programs/cli/gpg.nix
-    ./programs/cli/password-store.nix
-
-    ./services/pipewire.nix
-    ./programs/easyeffects.nix
-    ./programs/usbmuxd.nix
-
-    ./programs/sway.nix
-
-    ./programs/swaylock.nix
-    ./programs/gammastep.nix
-    ./programs/waybar
-    ./programs/mako.nix
-    ./programs/AusweisApp2.nix
-
-    ./programs/alacritty.nix
-
-    ./programs/firefox.nix
-    ./programs/thunderbird.nix
-
-    ./programs/mpv.nix
-    ./programs/imv.nix
-
-    ./programs/cli/ansible.nix
-    ./programs/cli/texlive.nix
-    ./programs/sublime-text3.nix
-    ./programs/libreoffice.nix
-    ./programs/gimp
-
-    ./programs/thunar.nix
-    ./programs/utilities.nix
-
-    ./services/syncthing.nix
-  ];
-}
diff --git a/configurations/bluetooth.nix b/configurations/linux/bluetooth.nix
diff --git a/configurations/linux/desktop-sway.nix b/configurations/linux/desktop-sway.nix
@@ -0,0 +1,86 @@
+{ config, lib, pkgs, home-manager, ... }:
+
+{
+  nixpkgs.config.allowUnfree = true;
+  environment.noXlibs        = false;
+
+  hardware = {
+    opengl = {
+      enable        = true;
+      driSupport    = true;
+      extraPackages = with pkgs; [
+        vaapiIntel
+        vaapiVdpau
+        libvdpau-va-gl
+        intel-media-driver
+      ];
+    };
+
+    trackpoint = {
+      enable       = true;
+      device       = "TPPS/2 JYT_Synaptics TrackPoint";
+      emulateWheel = true;
+      speed        = 85;
+      sensitivity  = 80;
+    };
+  };
+
+  programs = {
+    dconf.enable = true;
+  };
+
+  services = {
+    nscd.enable         = true;
+    getty.autologinUser = "leah";
+  };
+
+  users.users.leah.extraGroups = [ "dialout" ];
+
+  home-manager.users.leah = {
+    manual.html.enable = true;
+  };
+
+  imports = [
+    ./fonts.nix
+    ./gtk.nix
+    ./qt.nix
+    ./xdg.nix
+
+    ../programs/systemd-lock-handler.nix
+
+    ../programs/cli/gpg.nix
+    ../programs/cli/password-store.nix
+
+    ../services/pipewire.nix
+    ../programs/easyeffects.nix
+    ../programs/usbmuxd.nix
+
+    ../programs/sway.nix
+
+    ../programs/swaylock.nix
+    ../programs/gammastep.nix
+    ../programs/waybar
+    ../programs/mako.nix
+    ../programs/AusweisApp2.nix
+
+    ../programs/alacritty.nix
+
+    ../programs/firefox.nix
+    ../programs/thunderbird.nix
+
+    ../programs/mpv.nix
+    ../programs/imv.nix
+
+    ../programs/cli/ansible.nix
+    ../programs/cli/texlive.nix
+    ../programs/sublime-text3.nix
+    ../programs/libreoffice.nix
+    ../programs/gimp
+
+    ../programs/thunar.nix
+    ../programs/utilities.nix
+
+    ../services/syncthing.nix
+  ];
+
+}
diff --git a/configurations/fonts.nix b/configurations/linux/fonts.nix
diff --git a/configurations/gtk.nix b/configurations/linux/gtk.nix
diff --git a/configurations/mobile-device.nix b/configurations/linux/mobile-device.nix
diff --git a/configurations/qt.nix b/configurations/linux/qt.nix
diff --git a/configurations/sdr.nix b/configurations/linux/sdr.nix
diff --git a/configurations/thunderbolt.nix b/configurations/linux/thunderbolt.nix
diff --git a/configurations/xdg.nix b/configurations/linux/xdg.nix
diff --git a/machines/blechbuechse/darwin-configuration.nix b/machines/blechbuechse/darwin-configuration.nix
@@ -1,37 +1,12 @@
 { config, pkgs, lib, ... }:
 
 {
-
   imports = [
-    <home-manager/nix-darwin>
-
-    ../../modules/darwin/quirks.nix
-    ../../helpers/make-nixpkgs.nix
-
-    ../../configurations/darwin/nixpkgs-overrides.nix
-    ../../configurations/darwin/systemSettings.nix
-    ../../configurations/darwin/appSettings.nix
-    ../../configurations/darwin/keyboard.nix
-    ../../configurations/darwin/trackpad.nix
-    ../../configurations/darwin/homebrew.nix
-    ../../configurations/darwin/finder.nix
-    ../../configurations/darwin/skhd.nix
-    ../../configurations/darwin/yabai.nix
-    ../../configurations/darwin/speakers.nix
+    ../../configurations/common
 
-    ../../configurations/programs/cli/bash.nix
-    ../../configurations/programs/cli/micro.nix
-    ../../configurations/programs/cli/ssh.nix
-    ../../configurations/programs/cli/git.nix
-    ../../configurations/programs/cli/tmux.nix
-    ../../configurations/programs/cli/htop.nix
     ../../configurations/programs/cli/gpg.nix
     ../../configurations/programs/cli/password-store.nix
     ../../configurations/programs/cli/texlive.nix
-    ../../configurations/programs/cli/utilities.nix
-    ../../configurations/programs/cli/network-utilities.nix
-    ../../configurations/programs/cli/scripts.nix
-    ../../configurations/programs/cli/garminexport.nix
 
     ./syncthing.nix
   ];
diff --git a/machines/blechkasten/darwin-configuration.nix b/machines/blechkasten/darwin-configuration.nix
@@ -3,35 +3,11 @@
 {
 
   imports = [
-    <home-manager/nix-darwin>
+    ../../configurations/common
 
-    ../../modules/darwin/quirks.nix
-    ../../helpers/make-nixpkgs.nix
-
-    ../../configurations/darwin/nixpkgs-overrides.nix
-    ../../configurations/darwin/systemEnvironment.nix
-    ../../configurations/darwin/systemSettings.nix
-    ../../configurations/darwin/appSettings.nix
-    ../../configurations/darwin/keyboard.nix
-    ../../configurations/darwin/trackpad.nix
-    ../../configurations/darwin/homebrew.nix
-    ../../configurations/darwin/finder.nix
-    ../../configurations/darwin/skhd.nix
-    ../../configurations/darwin/yabai.nix
-    ../../configurations/darwin/speakers.nix
-
-    ../../configurations/programs/cli/bash.nix
-    ../../configurations/programs/cli/micro.nix
-    ../../configurations/programs/cli/ssh.nix
-    ../../configurations/programs/cli/git.nix
-    ../../configurations/programs/cli/tmux.nix
-    ../../configurations/programs/cli/htop.nix
     ../../configurations/programs/cli/gpg.nix
     ../../configurations/programs/cli/password-store.nix
     ../../configurations/programs/cli/texlive.nix
-    ../../configurations/programs/cli/utilities.nix
-    ../../configurations/programs/cli/network-utilities.nix
-    ../../configurations/programs/cli/scripts.nix
 
     ./syncthing.nix
   ];
diff --git a/machines/coladose/configuration.nix b/machines/coladose/configuration.nix
@@ -4,13 +4,13 @@
   imports = [
     ./hardware-configuration.nix
 
-    ../../configurations/mobile-device.nix
-    ../../configurations/thunderbolt.nix
-    ../../configurations/common.nix
+    ../../configurations/common
 
-    ../../configurations/desktop-sway.nix
-    ../../configurations/bluetooth.nix
-    ../../configurations/sdr.nix
+    ../../configurations/linux/mobile-device.nix
+    ../../configurations/linux/desktop-sway.nix
+    ../../configurations/linux/thunderbolt.nix
+    ../../configurations/linux/bluetooth.nix
+    ../../configurations/linux/sdr.nix
   ];
 
   hardware.cpu.intel.updateMicrocode = true;
diff --git a/machines/desastro/configuration.nix b/machines/desastro/configuration.nix
@@ -3,7 +3,8 @@
 {
   imports = [
     ./hardware-configuration.nix
-    ../../configurations/common.nix
+    ../../configurations/common
+
     ../../configurations/notify-failure.nix
 
     ../../configurations/services/prometheus-node-exporter.nix
diff --git a/machines/hector/configuration.nix b/machines/hector/configuration.nix
@@ -4,7 +4,8 @@
 
   imports = [
     ./hardware-configuration.nix
-    ../../configurations/common.nix
+    ../../configurations/common
+
     ../../configurations/notify-failure.nix
 
     ../../configurations/services/prometheus-node-exporter.nix
diff --git a/machines/lollo/configuration.nix b/machines/lollo/configuration.nix
@@ -3,7 +3,8 @@
 {
   imports = [
     ./hardware-configuration.nix
-    ../../configurations/common.nix
+    ../../configurations/common
+
     ../../configurations/notify-failure.nix
     ../../configurations/services/prometheus-node-exporter.nix
 
diff --git a/machines/osterei/configuration.nix b/machines/osterei/configuration.nix
@@ -4,7 +4,8 @@
 
   imports = [
     ./hardware-configuration.nix
-    ../../configurations/common.nix
+    ../../configurations/common
+
     ../../configurations/notify-failure.nix
 
     # dns server
diff --git a/machines/wanderduene/configuration.nix b/machines/wanderduene/configuration.nix
@@ -4,7 +4,7 @@
 
   imports = [
     ./hardware-configuration.nix
-    ../../configurations/common.nix
+    ../../configurations/common
 
     ../../configurations/services/prometheus-node-exporter.nix
     ../../configurations/services/bind
diff --git a/modules/default.nix b/modules/default.nix
@@ -1,9 +1,17 @@
+{ lib, ... }:
+
 {
 
-  imports = [
-    ./restic-backups.nix
-    ./vnstati
-    ./desktop-speakers.nix
-  ];
+  imports = (builtins.concatLists [
+    (if (builtins.currentSystem == "x86_64-linux") then [
+     ./restic-backups.nix
+     ./vnstati
+     ./desktop-speakers.nix
+    ] else [])
+    (if (builtins.currentSystem == "aarch64-darwin") then [
+      ./darwin/quirks.nix
+      ./darwin/hidutil.nix
+    ] else [])
+  ]);
 
 }
diff --git a/pkgs/default.nix b/pkgs/default.nix
@@ -2,6 +2,15 @@
 
 {
 
+  imports = (builtins.concatLists [
+    (if (builtins.currentSystem == "x86_64-linux") then [
+     ./overlays/linux.nix
+    ] else [])
+    (if (builtins.currentSystem == "aarch64-darwin") then [
+      ./overlays/darwin.nix
+    ] else [])
+  ]);
+
   nixpkgs.overlays = [
     (final: prev: {
 
diff --git a/configurations/darwin/nixpkgs-overrides.nix b/pkgs/overlays/darwin.nix
diff --git a/pkgs/overlays/linux.nix b/pkgs/overlays/linux.nix
@@ -0,0 +1,11 @@
+{ pkgs, lib, ... }:
+
+{
+
+  nixpkgs.overlays = [
+    (final: prev: {
+
+    })
+  ];
+
+}