]> Git — Sourcephile - julm/julm-nix.git/blob - home-manager/profiles/mpv.nix
fprintd: document
[julm/julm-nix.git] / home-manager / profiles / mpv.nix
1 { pkgs, lib, config, ... }:
2 {
3 home.packages = [
4 pkgs.mpv
5 ];
6 xdg.configFile."mpv/input.conf".text = ''
7 # Volume normalization
8 # See https://github.com/mpv-player/mpv/issues/3979
9 Alt+a cycle-values af "dynaudnorm=f=75:g=25:n=0:p=0.58" "loudnorm" ""
10 Alt+f cycle video-unscaled
11 '';
12 xdg.configFile."mpv/mpv.conf".text = ''
13 # Do not require DISPLAY for audio files
14 audio-display=no
15 hwdec=auto-safe
16 profile=gpu-hq
17 # Terminal is disabled by --player-operation-mode=pseudo-gui in mpv.desktop
18 terminal=yes
19 vo=gpu
20 ytdl-format=18/mp4-480p/hls-480p/http-360p/mp4
21 '';
22 # Prioritize mpv over mplayer
23 xdg.mimeApps.defaultApplications = {
24 "audio/mpeg" = ["mpv.desktop"];
25 "audio/ogg" = ["mpv.desktop"];
26 "audio/opus" = ["mpv.desktop"];
27 "video/mp4" = ["mpv.desktop"];
28 "video/x-matroska" = [ "mpv.desktop" ];
29 };
30 }