From fd662230c4e7415e770767e455cdde757115c2ea Mon Sep 17 00:00:00 2001 From: K900 Date: Fri, 26 Jul 2024 16:12:55 +0300 Subject: [PATCH] nixos/installer: ship only one mbrola voice per language This reduces the size of mbrola-voices by 387M (647M -> 260M) for all installers that ship with speechd, to make sure that they fit the output limits of hydra while not compromising too much on accessbility. Co-authored-by: Martin Weinelt --- nixos/modules/profiles/installation-device.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/nixos/modules/profiles/installation-device.nix b/nixos/modules/profiles/installation-device.nix index 0b10c0414147..913b6fc204dd 100644 --- a/nixos/modules/profiles/installation-device.nix +++ b/nixos/modules/profiles/installation-device.nix @@ -126,5 +126,15 @@ with lib; # allow nix-copy to live system nix.settings.trusted-users = [ "root" "nixos" ]; + + # Install less voices for speechd to save some space + services.speechd.package = pkgs.speechd.override { + mbrola = pkgs.mbrola.override { + mbrola-voices = pkgs.mbrola-voices.override { + # only ship with one voice per language + languages = [ "*1" ]; + }; + }; + }; }; }