From 5d8920a349bf8e7ea3752dcf783e7b1754db9d5d Mon Sep 17 00:00:00 2001 From: NullBite Date: Fri, 29 Dec 2023 04:35:08 -0500 Subject: [PATCH] Move Bluetooth and Syncthing configuration --- fragments/hardware/bluetooth.nix | 7 +++++++ fragments/software/syncthing.nix | 9 +++++++++ hosts/slab/configuration.nix | 12 ------------ roles/desktop.nix | 2 ++ 4 files changed, 18 insertions(+), 12 deletions(-) create mode 100644 fragments/hardware/bluetooth.nix create mode 100644 fragments/software/syncthing.nix diff --git a/fragments/hardware/bluetooth.nix b/fragments/hardware/bluetooth.nix new file mode 100644 index 0000000..dd84452 --- /dev/null +++ b/fragments/hardware/bluetooth.nix @@ -0,0 +1,7 @@ +{ config, lib, pkgs, ...}: +{ + hardware.bluetooth = { + enable = lib.mkDefault true; + powerOnBoot = lib.mkDefault true; + }; +} diff --git a/fragments/software/syncthing.nix b/fragments/software/syncthing.nix new file mode 100644 index 0000000..da6d2da --- /dev/null +++ b/fragments/software/syncthing.nix @@ -0,0 +1,9 @@ +{ config, lib, pkgs, ...}: +{ + services.syncthing = { + enable = lib.mkDefault true; + user = lib.mkDefault "nullbite"; + dataDir = lib.mkDefault "/home/nullbite/Documents"; + configDir = lib.mkDefault "/home/nullbite/.config/syncthing"; + }; +} diff --git a/hosts/slab/configuration.nix b/hosts/slab/configuration.nix index 189c571..6228c3f 100644 --- a/hosts/slab/configuration.nix +++ b/hosts/slab/configuration.nix @@ -45,18 +45,6 @@ services.xserver.videoDrivers = ["amdgpu"]; - services.syncthing = { - enable = true; - user = "nullbite"; - dataDir = "/home/nullbite/Documents"; - configDir = "/home/nullbite/.config/syncthing"; - }; - - hardware.bluetooth = { - enable = true; - powerOnBoot = true; - }; - # {{{ old config # Use the systemd-boot EFI boot loader. # boot.loader.systemd-boot.enable = true; diff --git a/roles/desktop.nix b/roles/desktop.nix index b205b0f..33160e7 100644 --- a/roles/desktop.nix +++ b/roles/desktop.nix @@ -5,6 +5,8 @@ ./base.nix ../fragments/sound.nix ../fragments/multimedia.nix + ../fragments/software/syncthing.nix + ../fragments/hardware/bluetooth.nix ]; # Enable the X11 windowing system.