From fd5fbb0a241f644908cdf01ccd1821d0606fb4fd Mon Sep 17 00:00:00 2001 From: Dusk Banks Date: Mon, 20 Apr 2020 12:21:11 -0700 Subject: [PATCH] texlive: add `packageSet` option (cherry picked from commit 45f9cb06a9152ca367edc3e7eaa5449338885167) --- modules/programs/texlive.nix | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/modules/programs/texlive.nix b/modules/programs/texlive.nix index a49f4bf6..0921417b 100644 --- a/modules/programs/texlive.nix +++ b/modules/programs/texlive.nix @@ -6,7 +6,8 @@ let cfg = config.programs.texlive; - texlivePkgs = cfg.extraPackages pkgs.texlive; + texlive = cfg.packageSet; + texlivePkgs = cfg.extraPackages texlive; in { meta.maintainers = [ maintainers.rycee ]; @@ -15,6 +16,12 @@ in { programs.texlive = { enable = mkEnableOption "TeX Live"; + packageSet = mkOption { + default = pkgs.texlive; + defaultText = literalExample "pkgs.texlive"; + description = "TeX Live package set to use."; + }; + extraPackages = mkOption { default = tpkgs: { inherit (tpkgs) collection-basic; }; defaultText = "tpkgs: { inherit (tpkgs) collection-basic; }"; @@ -41,6 +48,6 @@ in { home.packages = [ cfg.package ]; - programs.texlive.package = pkgs.texlive.combine texlivePkgs; + programs.texlive.package = texlive.combine texlivePkgs; }; }