1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-12-02 23:21:02 +01:00
home-manager/tests/modules/programs/streamlink/streamlink-settings.nix
Austin Horstman cba2f9ce95 treewide: reformat nixfmt-rfc-style
Reformat repository using new nixfmt-rfc-style.
2025-04-08 08:50:05 -07:00

31 lines
725 B
Nix

{ pkgs, ... }:
{
programs.streamlink = {
enable = true;
settings = {
player = "mpv";
player-args = "--cache 2048";
player-no-close = true;
http-header = [
"User-Agent=Mozilla/5.0 (X11; Linux x86_64; rv:130.0) Gecko/20100101 Firefox/130.0"
"Accept-Language=en-US"
];
};
};
test.stubs.streamlink = { };
nmt.script =
let
streamlinkConfig =
if pkgs.stdenv.hostPlatform.isDarwin then
"Library/Application Support/streamlink/config"
else
".config/streamlink/config";
in
''
assertFileExists "home-files/${streamlinkConfig}"
assertFileContent "home-files/${streamlinkConfig}" ${./config}
'';
}