Skip to content

Commit

Permalink
nixos/tuxedo-driver: init
Browse files Browse the repository at this point in the history
  • Loading branch information
Keksgesicht committed Sep 21, 2024
1 parent 8a73aee commit fa639a1
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 34 deletions.
35 changes: 35 additions & 0 deletions nixos/modules/hardware/tuxedo-driver.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{ config, lib, ... }:
let
cfg = config.hardware.tuxedo-driver;
tuxedo-driver = config.boot.kernelPackages.tuxedo-driver;
in
{
imports = [
(lib.mkRenamedOptionModule
[
"hardware"
"tuxedo-keyboard"
]
[
"hardware"
"tuxedo-driver"
]
)
];

options.hardware.tuxedo-driver = {
enable = lib.mkEnableOption ''
The tuxedo-driver driver enables access to the following on TUXEDO notebooks:
- Driver for Fn-keys
- SysFS control of brightness/color/mode for most TUXEDO keyboards
- Hardware I/O driver for TUXEDO Control Center
For more inforation it is best to check at the source code description: <https://gitlab.com/tuxedocomputers/development/packages/tuxedo-drivers>
'';
};

config = lib.mkIf cfg.enable {
boot.kernelModules = [ "tuxedo_keyboard" ];
boot.extraModulePackages = [ tuxedo-driver ];
};
}
32 changes: 0 additions & 32 deletions nixos/modules/hardware/tuxedo-keyboard.nix

This file was deleted.

2 changes: 1 addition & 1 deletion nixos/modules/module-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@
./hardware/sensor/iio.nix
./hardware/steam-hardware.nix
./hardware/system-76.nix
./hardware/tuxedo-keyboard.nix
./hardware/tuxedo-driver.nix
./hardware/ubertooth.nix
./hardware/uinput.nix
./hardware/uni-sync.nix
Expand Down
2 changes: 1 addition & 1 deletion nixos/modules/services/hardware/tuxedo-rs.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ in

config = lib.mkIf cfg.enable (lib.mkMerge [
{
hardware.tuxedo-keyboard.enable = true;
hardware.tuxedo-driver.enable = true;

systemd = {
services.tailord = {
Expand Down

0 comments on commit fa639a1

Please sign in to comment.