diff options
Diffstat (limited to 'user-profiles/yt-dlp.nix')
-rw-r--r-- | user-profiles/yt-dlp.nix | 34 |
1 files changed, 18 insertions, 16 deletions
diff --git a/user-profiles/yt-dlp.nix b/user-profiles/yt-dlp.nix index 0af42786..1a30ab5a 100644 --- a/user-profiles/yt-dlp.nix +++ b/user-profiles/yt-dlp.nix | |||
@@ -1,21 +1,23 @@ | |||
1 | { config, lib, userName, pkgs, ... }: | 1 | { config, lib, userName, pkgs, ... }: |
2 | { | 2 | { |
3 | home-manager.users.${userName} = { | 3 | home-manager.users.${userName} = { |
4 | home.packages = with pkgs; [ yt-dlp ]; | 4 | programs.yt-dlp = { |
5 | xdg.configFile."yt-dlp/config".text = '' | 5 | enable = true; |
6 | --cookies-from-browser firefox | 6 | settings = { |
7 | --mark-watched | 7 | cookies-from-browser = "firefox"; |
8 | --format ${lib.concatStringsSep "/" [ | 8 | mark-watched = true; |
9 | "bestvideo[width<=3840][height<=2160][fps<=60]+bestaudio" | 9 | format = lib.concatStringsSep "/" [ |
10 | "best[width<=3840][height<=2160][fps<=60]" | 10 | "bestvideo[width<=3840][height<=2160][fps<=60]+bestaudio" |
11 | "best" | 11 | "best[width<=3840][height<=2160][fps<=60]" |
12 | ]} | 12 | "best" |
13 | --sub-langs all,-live_chat | 13 | ]; |
14 | --prefer-free-formats | 14 | sub-langs = "all,-live_chat,-rechat"; |
15 | --embed-metadata | 15 | prefer-free-formats = true; |
16 | --downloader ${pkgs.aria2}/bin/aria2c | 16 | embed-metadata = true; |
17 | --sponsorblock-mark all | 17 | downloader = "${pkgs.aria2}/bin/aria2c"; |
18 | --restrict-filenames | 18 | sponsorblock-mark = "all"; |
19 | ''; | 19 | restrict-filenames = true; |
20 | }; | ||
21 | }; | ||
20 | }; | 22 | }; |
21 | } | 23 | } |