about summary refs log tree commit diff
path: root/home/mpv
diff options
context:
space:
mode:
Diffstat (limited to 'home/mpv')
-rw-r--r--home/mpv/default.nix20
1 files changed, 20 insertions, 0 deletions
diff --git a/home/mpv/default.nix b/home/mpv/default.nix
new file mode 100644
index 0000000..7013c0b
--- /dev/null
+++ b/home/mpv/default.nix
@@ -0,0 +1,20 @@
+{ lib, config, ... }:
+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";
+      };
+      scripts = lib.attrVals [ "sponsorblock" ] pkgs.mpvScripts;
+    };
+  };
+}