mirror of
https://codeberg.org/jopejoe1/nix-conf.git
synced 2025-06-07 21:39:23 +02:00
Refactor Systems
This commit is contained in:
parent
4d7de09ec4
commit
9c32ed314c
8 changed files with 101 additions and 70 deletions
19
modules/hardware/bluetooth/default.nix
Normal file
19
modules/hardware/bluetooth/default.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{ options, config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
#with lib.internal;
|
||||
let cfg = config.custom.hardware.bluetooth;
|
||||
in
|
||||
{
|
||||
options.custom.hardware.bluetooth = with types; {
|
||||
enable = mkBoolOpt false "Whether or not to enable bluetooth";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
hardware.bluetooth.enable = true;
|
||||
hardware.bluetooth.hsphfpd.enable = !config.services.pipewire.wireplumber.enable;
|
||||
hardware.bluetooth.powerOnBoot = true;
|
||||
|
||||
};
|
||||
}
|
19
modules/hardware/rgb/default.nix
Normal file
19
modules/hardware/rgb/default.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{ options, config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
#with lib.internal;
|
||||
let cfg = config.custom.hardware.rgb;
|
||||
in
|
||||
{
|
||||
options.custom.hardware.rgb = with types; {
|
||||
enable = mkBoolOpt false "Whether or not to enable openrgb";
|
||||
motherboard = mkOpt str "intel" "Which motherboard to use"; # Move to common CPU module at some point
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
services.hardware.openrgb.enable = true;
|
||||
services.hardware.openrgb.motherboard = cfg.motherboard;
|
||||
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue