summaryrefslogtreecommitdiff
path: root/user-profiles/yt-dlp.nix
blob: 89a269901d9779a2fc3b8cf56ec19f4fc65e0fff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
{ config, lib, userName, pkgs, ... }:
{
  home-manager.users.${userName} = {
    home.packages = with pkgs; [ yt-dlp ];
    xdg.configFile."yt-dlp/config".text = ''
      --netrc
      --mark-watched
      --format ${lib.concatStringsSep "/" [
        "bestvideo[width<=3840][height<=2160][fps<=60][protocol!=http_dash_segments]+bestaudio[protocol!=http_dash_segments]"
        "best[width<=3840][height<=2160][fps<=60][protocol!=http_dash_segments]"
        "best[protocol!=http_dash_segments]"
      ]}
      --sub-langs all,-live_chat
    '';
  };
}