1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-23 11:39:46 +01:00
home-manager/modules/programs/obs-studio.nix

49 lines
1.1 KiB
Nix
Raw Normal View History

2018-09-26 05:55:51 +02:00
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.programs.obs-studio;
2020-02-02 00:39:17 +01:00
in {
2018-09-26 05:55:51 +02:00
meta.maintainers = [ maintainers.adisbladis ];
options = {
programs.obs-studio = {
enable = mkEnableOption "obs-studio";
package = mkOption {
type = types.package;
default = pkgs.obs-studio;
defaultText = literalExpression "pkgs.obs-studio";
description = ''
OBS Studio package to install.
'';
};
finalPackage = mkOption {
type = types.package;
visible = false;
readOnly = true;
description = "Resulting customized OBS Studio package.";
};
2018-09-26 05:55:51 +02:00
plugins = mkOption {
2020-02-02 00:39:17 +01:00
default = [ ];
example = literalExpression "[ pkgs.obs-studio-plugins.wlrobs ]";
2018-09-26 05:55:51 +02:00
description = "Optional OBS plugins.";
type = types.listOf types.package;
};
};
};
config = mkIf cfg.enable {
home.packages = [ cfg.finalPackage ];
programs.obs-studio.finalPackage =
pkgs.wrapOBS.override { obs-studio = cfg.package; } {
plugins = cfg.plugins;
};
2018-09-26 05:55:51 +02:00
};
}