MusicPlayerDaemon / mpc

Command-line client for MPD
GNU General Public License v2.0
191 stars 36 forks source link

[Feature Request] Allow use of UNIX socket #75

Closed gearhead closed 2 years ago

gearhead commented 2 years ago

Port cannot be set to a unix socket. Only works with a TCP port. It would be nice if '--port=/run/mpd/socket' would be accepted. Currently, it only accepts port numbers and not sockets.

# mpc --port=6600 status
Underground Eighties: UK Synthpop and a bit of New Wave. [SomaFM]: Colourbox - Breakdown (12 Version 1) (Remastered)
[playing] #5/5  37:25/0:00 (0%)
volume: 40%   repeat: off   random: off   single: off   consume: off
# mpc --port=/run/mpd/socket status
Port "/run/mpd/socket" is not a positive integer
# ls -al /run/mpd/
total 4
drwxr-xr-x  2 mpd  mpd   80 Nov 20 10:33 .
drwxrwxrwx 29 root root 660 Nov 20 10:33 ..
-rw-r--r--  1 mpd  mpd    4 Nov 20 10:33 pid
srw-rw-rw-  1 mpd  mpd    0 Nov 20 10:33 socket
MaxKellermann commented 2 years ago

mpc --host=/run/mpd/socket It's documented on the manpage.