{
  pkgs,
  lib,
  ...
}: let
  configFile = "mpv/mpv.conf";
  mpvInputFile = "mpv/input.conf";
in {
  users.users.someone.packages = with pkgs; [
    mpv
    mpvScripts.mpris
  ];

  xdg.configFile."${configFile}".text =
    lib.generators.toKeyValue {
      mkKeyValue = k: v: "${lib.escapeShellArg k}=${lib.escapeShellArg v}";
      listsAsDuplicateKeys = true;
    } {
      profile = "gpu-hq";
      volume = "100";
    };

  xdg.configFile."${mpvInputFile}".text = ''
    l af add @pan:stereo|c0=c0|c1=c0
    r af add @pan:stereo|c0=c1|c1=c1
    c show-text "Chapters:\n''${chapter-list}"
    s ignore
  '';
}
