Update mpd configuration

This commit is contained in:
Sonny Bakker 2024-09-16 08:34:45 +02:00
parent ebb8f8c2c2
commit b1965fc631
5 changed files with 65 additions and 6 deletions

View file

@ -22,6 +22,7 @@
loop:
- { path: '{{ mpd_configuration_dir }}', state: 'directory' }
- { path: '{{ ncmpc_configuration_dir }}', state: 'directory' }
- { path: '{{ ncmpcpp_configuration_dir }}', state: 'directory' }
- { path: '{{ mpd_configuration_dir }}/playlists', state: 'directory' }
- { path: '{{ mpd_configuration_dir }}/state', state: 'touch' }
@ -41,8 +42,14 @@
loop:
- { src: 'templates/mpd/mpd.conf.j2', dest: '{{ mpd_configuration_dir }}/mpd.conf' }
- { src: 'templates/mpd/ncmpc.j2', dest: '{{ ncmpc_configuration_dir }}/config' }
- { src: 'templates/mpd/ncmpcpp/config.j2', dest: '{{ ncmpcpp_configuration_dir }}/config' }
- {
src: 'templates/mpd/ncmpcpp/bindings.j2',
dest: '{{ ncmpcpp_configuration_dir }}/bindings'
}
notify:
- stop mpd service
# TODO: install https://aur.archlinux.org/mpd-mpris-bin.git from AUR
# Use mpc to control local mpd server.
# Use $ mpc add http://{{ mpd_remote_address }}:{{ mpd_remote_stream_port }}

View file

@ -3,7 +3,8 @@
bind_to_address "{{ mpd_listen_address }}"
port "{{ mpd_listen_port }}"
playlist_directory "{{ mpd_configuration_dir }}/playlists"
playlist_directory "{{ mpd_configuration_dir }}/playlists"
state_file "{{ mpd_configuration_dir }}/state"
database {
plugin "proxy"
@ -12,11 +13,9 @@ database {
}
audio_output {
type "pulse"
name "mpd"
replay_gain_handler "software"
mixer_type "hardware"
format "128000:24:2"
name "mpd"
type "pipewire"
dsd "yes"
}
input {

View file

@ -0,0 +1,16 @@
# {{ ansible_managed }}
def_key "l"
next_column
def_key "h"
previous_column
def_key "k"
scroll_up
def_key "j"
scroll_down
def_key "l"
jump_to_playing_song
def_key "a"
add_item_to_playlist

View file

@ -0,0 +1,36 @@
# {{ ansible_managed }}
#
############## Connection ###################
## Connect to mpd running on a specified host
mpd_host = 10.0.0.1
## Connect to mpd on the specified port.
mpd_port = 21000
# header_visibility = yes
# playlist_show_mpd_host = yes
# titles_visibility = yes
# enable_window_title = yes
connected_message_on_startup = no
display_bitrate = yes
############## Theme ###################
user_interface = classic
song_columns_list_format = "(40)[9]{t|f} (25)[245]{a} (25)[245]{b} (25)[245]{l}"
song_list_format = "{$5 %a$9 $1│$9 $8%t$9 }|{ $8%f$9}$R{$5%b $7}"
# Column Names
header_window_color = 1
# Main window
main_window_color = 1
# Bottombar
progressbar_color = 1
player_state_color = 1

View file

@ -7,3 +7,4 @@ mpd_remote_stream_port: '8000' # note that this is not used (yet)
mpd_configuration_dir: '{{ ansible_env.HOME }}/.config/mpd'
ncmpc_configuration_dir: '{{ ansible_env.HOME }}/.config/ncmpc'
ncmpcpp_configuration_dir: '{{ ansible_env.HOME }}/.config/ncmpcpp'