Skip to content

Instantly share code, notes, and snippets.

@andreanidouglas
Last active May 20, 2018 03:59
Show Gist options
  • Save andreanidouglas/57eea09da795437fad3d2c64d69d49df to your computer and use it in GitHub Desktop.
Save andreanidouglas/57eea09da795437fad3d2c64d69d49df to your computer and use it in GitHub Desktop.
MPD Configuration

Setup /etc/mpd.conf

music_directory "/mnt/Media/Musics"
playlist_directory "/opt/mpd"
db_file "/opt/mpd/mpd.db"

log_file "/opt/mpd/mpd.log"
pid_file "/opt/mpd/mpd.pid"
state_file "/opt/mpd/mpdstate"

user "mpd"

audio_output {
        type "pulse"
        name "pulse audio"
}

audio_output {

        type "fifo"
        name "my_fifo"
        path "/tmp/mpd.fifo"
        format "44100:16:2"
}

Create mpd user and data directories

useradd mpd -M -s /bin/false
mkdir /opt/mpd
chown -R mpd:mpd /opt/mpd

Enable pulse audio Autospawn

edit /etc/pulse/client.conf

autospawn = yes

Enable audio visualizer for ncmpcpp

edit ~/.ncmpcpp/config

visualizer_fifo_path = "/tmp/mpd.fifo"
visualizer_output_name = "my_fifo"
visualizer_sync_interval = "30" 
visualizer_in_stereo = "yes"
visualizer_type = "spectrum"
visualizer_look = "+|"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment