aboutsummaryrefslogblamecommitdiff
path: root/home/mpv/default.nix
blob: c2a3a6afd573230aa61ae12db296331532ae3f7b (plain) (tree)
1
2
3
4
                           
                             

  











                                                






                                                                          




                                                                
{ lib, config, pkgs, ... }:
let cfg = config.my.home.mpv;
in
{
  options.my.home.mpv = with lib; {
    enable = mkEnableOption "mpv configuration";
  };

  config = lib.mkIf cfg.enable {
    programs.mpv = {
      enable = true;
      config = {
        sub-auto = "fuzzy";
        vo = "gpu";
        hwdec = "auto-safe";
        gpu-context = "wayland";
        audio-display = "no";
        cache-pause = "no";
        cache = "yes";
        mute = "no";
        osc = "yes";
        screenshot-directory = "~/documents/screenshots/mpv-screenshots/";
        screenshot-format = "png";
      };
      scripts = lib.attrVals [ "sponsorblock" ] pkgs.mpvScripts;
    };
  };
}