From 7ab1d4b9e1f4adc43c3078cb50df70a0f5471848 Mon Sep 17 00:00:00 2001 From: Tom Alexander Date: Fri, 6 Feb 2026 11:24:05 -0500 Subject: [PATCH] Add the v4l utilities to control webcam settings. --- nix/configuration/configuration.nix | 1 + nix/configuration/hosts/odo/default.nix | 1 + nix/configuration/hosts/odowork/default.nix | 1 + nix/configuration/hosts/quark/default.nix | 1 + nix/configuration/roles/webcam/default.nix | 25 +++++++++++++++++++++ 5 files changed, 29 insertions(+) create mode 100644 nix/configuration/roles/webcam/default.nix diff --git a/nix/configuration/configuration.nix b/nix/configuration/configuration.nix index fdc1ced5..1ca841e7 100644 --- a/nix/configuration/configuration.nix +++ b/nix/configuration/configuration.nix @@ -93,6 +93,7 @@ ./roles/vscode ./roles/wasm ./roles/waybar + ./roles/webcam ./roles/wine ./roles/wireguard ./roles/yubikey diff --git a/nix/configuration/hosts/odo/default.nix b/nix/configuration/hosts/odo/default.nix index e026c55b..d3840dff 100644 --- a/nix/configuration/hosts/odo/default.nix +++ b/nix/configuration/hosts/odo/default.nix @@ -148,6 +148,7 @@ me.vscode.enable = true; me.wasm.enable = true; me.waybar.enable = true; + me.webcam.enable = true; me.wine.enable = false; me.wireguard.activated = [ "drmario" diff --git a/nix/configuration/hosts/odowork/default.nix b/nix/configuration/hosts/odowork/default.nix index 8dce6c33..4dbbe2e6 100644 --- a/nix/configuration/hosts/odowork/default.nix +++ b/nix/configuration/hosts/odowork/default.nix @@ -139,6 +139,7 @@ me.vscode.enable = true; me.vscode.enable_work_profile = true; me.waybar.enable = true; + me.webcam.enable = true; me.wireguard.activated = [ "wgh" ]; diff --git a/nix/configuration/hosts/quark/default.nix b/nix/configuration/hosts/quark/default.nix index c15b981c..edbde851 100644 --- a/nix/configuration/hosts/quark/default.nix +++ b/nix/configuration/hosts/quark/default.nix @@ -143,6 +143,7 @@ me.vscode.enable = true; me.wasm.enable = true; me.waybar.enable = true; + me.webcam.enable = true; me.wine.enable = false; me.wireguard.activated = [ "drmario" diff --git a/nix/configuration/roles/webcam/default.nix b/nix/configuration/roles/webcam/default.nix new file mode 100644 index 00000000..871ad46d --- /dev/null +++ b/nix/configuration/roles/webcam/default.nix @@ -0,0 +1,25 @@ +{ + config, + lib, + pkgs, + ... +}: + +{ + imports = [ ]; + + options.me = { + webcam.enable = lib.mkOption { + type = lib.types.bool; + default = false; + example = true; + description = "Whether we want to install webcam."; + }; + }; + + config = lib.mkIf config.me.webcam.enable { + environment.systemPackages = with pkgs; [ + v4l-utils + ]; + }; +}