music_player to dwm

This commit is contained in:
Sam 2024-07-04 17:19:33 +01:00
parent 8c13a24cc8
commit f6290f3215
2 changed files with 66 additions and 0 deletions

View File

@ -9,6 +9,7 @@
./picom.nix ./picom.nix
./xresources.nix ./xresources.nix
./dunst.nix ./dunst.nix
./music_player.nix
# Status bar scripts # Status bar scripts
./scripts/sb-cpu-pct.nix ./scripts/sb-cpu-pct.nix

View File

@ -0,0 +1,65 @@
{ pkgs, config, ... }:
{
home.file."mus/music_data".source = config.lib.file.mkOutOfStoreSymlink /media/music/music_data;
home.packages = [
pkgs.ffmpeg
pkgs.nsxiv
pkgs.kunst
pkgs.mpc-cli
pkgs.jq
pkgs.imagemagick
];
services.mpd = {
enable = true;
package = pkgs.mpd;
extraConfig = ''
music_directory "~/mus/music_data"
playlist_directory "~/.local/share/mpd/playlists"
log_file "~/.local/share/mpd/log"
db_file "~/.local/share/mpd/database"
pid_file "~/.local/share/mpd/pid"
state_file "~/.local/share/mpd/state"
sticker_file "~/.local/share/mpd/sticker.sql"
auto_update "yes"
audio_output {
type "pipewire"
name "PipeWire Sound Server"
}
audio_output {
type "fifo"
name "Visualizer feed"
path "/tmp/mpd.fifo"
format "44100:16:2"
}
bind_to_address "127.0.0.1" '';
musicDirectory = "~/mus/music_data";
};
programs.ncmpcpp = {
enable = true;
package = (pkgs.ncmpcpp.override { visualizerSupport = true; });
mpdMusicDir = "~/mus/music_data";
settings = {
mpd_host = "127.0.0.1";
mpd_port = "6600";
visualizer_data_source = "/tmp/mpd.fifo";
visualizer_output_name = "Visualizer Feed";
visualizer_in_stereo = "yes";
visualizer_type = "spectrum";
visualizer_fps = "60";
visualizer_autoscale = "no";
visualizer_look = "";
visualizer_color = "169, 170, 169, 135, 134, 133, 129, 128, 127, 126, 125, 124";
visualizer_spectrum_smooth_look = "yes";
visualizer_spectrum_dft_size = "3";
};
};
}