2019-09-17 16:48:19 +04:00
|
|
|
{ config, lib, pkgs, ... }:
|
2020-08-15 19:36:16 +04:00
|
|
|
{
|
2022-12-10 22:34:39 +03:00
|
|
|
home-manager.users.${config.mainuser} = {
|
|
|
|
programs.mpv = {
|
|
|
|
enable = true;
|
|
|
|
config = {
|
|
|
|
vo = "gpu";
|
|
|
|
gpu-context = "wayland";
|
|
|
|
save-position-on-quit = "yes";
|
|
|
|
hwdec = if config.deviceSpecific.devInfo.gpu.vendor == "nvidia" then
|
|
|
|
"vdpau"
|
|
|
|
else
|
|
|
|
"vaapi";
|
|
|
|
ytdl-format = if config.deviceSpecific.isLaptop then
|
|
|
|
"bestvideo[height<=?1080]+bestaudio/best"
|
|
|
|
else
|
|
|
|
"bestvideo[height<=?2160]+bestaudio/best";
|
|
|
|
};
|
2019-09-17 23:07:22 +04:00
|
|
|
};
|
2022-12-10 22:34:39 +03:00
|
|
|
home.file.".config/yt-dlp/config".text = ''
|
2022-04-22 02:14:31 +03:00
|
|
|
--cookies-from-browser firefox
|
2019-09-22 01:32:26 +04:00
|
|
|
--mark-watched
|
|
|
|
'';
|
|
|
|
};
|
2023-03-27 16:00:57 +03:00
|
|
|
|
|
|
|
persist.state.homeDirectories = [
|
|
|
|
".config/mpv"
|
|
|
|
];
|
2019-09-17 02:20:32 +04:00
|
|
|
}
|