configuration.nix/home/programs/mpv.nix
2023-07-11 22:11:11 +05:30

25 lines
503 B
Nix

{
pkgs,
...
}: {
programs.mpv = {
enable = true;
package = pkgs.mpv.override {youtubeSupport = true;};
config = {
cache = "yes";
cache-secs = "120";
hwdec = "auto-safe";
gpu-context = "wayland";
};
defaultProfiles = ["gpu-hq"];
scripts = with pkgs.mpvScripts; [mpris];
};
xdg.desktopEntries = {
"umpv" = {
name = "umpv Media Player";
exec = "umpv --player-operation-mode=pseudo-gui -- %U";
noDisplay = true;
};
};
}