An mpc-like control interface for mpv.
An mpc-like control interface for the mpv player with a nearly complete compatibility layer for mpc commands in addition to GNU style arguments. This forks lwillets/mpvc providing some extra goodies such as: improved CLI, TUI, FZF, WEB & playing media from YouTube & streaming services. Check the Wiki, LogBook & Casts for a detailed view of the extra features of this fork.
mpvc functionality is provided by:
For more details on how to use the above tools have a look at the logbok.html. In addition, the casts/ directory to shows some screencasts of mpvc in action.
mpvc-installer fetch-user: installs mpvc under BINDIR=~/bin/
curl -fsSL -o mpvc-installer https://github.com/gmt4/mpvc/raw/master/extras/mpvc-installer && sh ./mpvc-installer fetch-user
# fetch a local copy of the github repo git clone https://github.com/gmt4/mpvc/ # use extras/mpvc-installer: just copy/link to your $HOME/bin (cd mpvc; extras/mpvc-installer link-user) # use mpvc-fzf to search and play youtube media mpvc-fzf -p 'kupla mirage' # use mpvc to add/load/save media files or online YT URLs mpvc add /path/to/your/*.mp3 # or your URLs find . -type f -name | mpvc load mpvc save my-playlist # use mpvc-fzf to manage the playlist mpvc-fzf -f # use mpvc-tui to start the tui + desktop notifications mpvc-tui -T
mpvc-tui -T: running the mpvc TUI
Required:
mpv
socat
: is recommended due to the differing implementations of netcat
across UNIXes.awk
: a sane version of awk
is recommendedRecommended extras:
curl
fzf
notify-send
Debian (and derivatives such as Ubuntu):
apt install mpv gawk curl socat fzf rlwrap jq libnotify-bin
Arch (and derivatives):
pacman -Sy mpv gawk curl socat fzf rlwrap jq libnotify
BSD (and pkg(1) based derivatives):
pkg install -y mpv gawk curl socat fzf rlwrap jq libnotify
MacOS (and brew(1) based derivatives see FAQ):
brew install gawk socat fzf rlwrap jq gnu-sed yt-dlp # mpv curl libnotify
Check for missing dependencies using mpvc-installer check-reqs
To install mpvc:
Distro packages:
pacaur -y mpvc-git
mpvc-git
emerge mpvc
mpvc
nix-env -i mpvc
mpvc
mpvc requires the use of mpv and its --input-ipc-server
option.
mpvc automatically opens an ipc-server for you when adding files to be played, but by default will close the ipc-server when all files have finished playing.
To keep the ipc-server open permanently, use:
$ mpv --input-ipc-server=/tmp/mpvsocket
You can also specify the default ipc server in your $XDG_CONFIG_HOME/mpv.conf
which will make the most recent mpv instance you start be controllable via mpvc:
input-ipc-server=/tmp/mpvsocket
However, this may not be suitable if you have background music added to the socket and then open a video using mpv. The new mpv instance will be controllable through the socket, but the previous instance is not. You can get around this by adding the video via mpvc, and manually switching to the video.
Some basic tricks are provided in QuickStart. For more tips on loading/saving/maniputaling the mpv playlist/state, managing av/vf filters, etc. are provided in the LogBook.
player
set to
mpvc and playerargs
set to add.Like any piece of software, mpvc is not perfect:
Check out the Issue Tracker for further improvements to be made.