(mirror) personal dotfiles
github.com/crescentrose/dotfiles
1{
2 imports = [
3 ../../modules/services/mprisence.nix
4 ];
5
6 age.secrets.mpdscribble.file = ../../secrets/mpdscribble.age;
7
8 services = {
9 mpd = {
10 enable = false;
11 musicDirectory = "/mnt/media/Music";
12 extraConfig = ''
13 auto_update "yes"
14
15 audio_output {
16 type "pipewire"
17 name "PipeWire Sound Server"
18 }
19
20 audio_output {
21 type "fifo"
22 name "visualizer"
23 path "~/.local/share/mpd/mpd.fifo"
24 format "44100:16:2"
25 }
26 '';
27 };
28
29 # control mpd through the MPRIS protocol
30 mpd-mpris.enable = false;
31
32 # daemon that tracks media player activity
33 playerctld.enable = true;
34
35 # Make Bluetooth headset buttons usable with media players
36 mpris-proxy.enable = true;
37
38 # Enable Discord rich presence
39 mprisence = {
40 enable = false;
41 settings = {
42 player = {
43 default = {
44 ignore = true;
45 };
46 "io.github.htkhiem.Euphonica" = {
47 ignore = true;
48 };
49 "*mpd*" = {
50 ignore = false;
51 };
52 zen = {
53 ignore = true;
54 };
55 };
56 };
57 };
58
59 # Enable scrobbling
60 mpdscribble = {
61 enable = false;
62 endpoints."last.fm" = {
63 passwordFile = "/run/user/1000/agenix/mpdscribble"; # TODO: super hacky
64 username = "crescentr0se";
65 };
66 };
67 };
68
69 # Ensure that the mpd state directory exists for the FIFO to be created
70 xdg.dataFile."mpd/.keep".text = "";
71}