Skip to content

sp1ff/mpdmacs

Repository files navigation

mpdmacs

https://melpa.org/packages/mpdmacs-badge.svg https://stable.melpa.org/packages/mpdmacs-badge.svg https://github.com/sp1ff/mpdmacs/workflows/melpazoid/badge.svg

Introduction

mpdmacs-mode is a global minor-mode that turns Emacs into a lightweight, ergonomic MPD client.

Prerequisites

Emacs 29.1 & elmpd latest.

Installing

This is available on MELPA as well as Autotools source tarballs:

curl -L -O https://github.com/mpdmacs/archive/0.3.0.tar.gz
tar xf mpdmacs-0.3.0.tar.gz && cd mpdmacs-0.3.0
./configure && make all check
sudo make install

Getting Started

Pull in mpdmacs as usual via require: (require 'mpdmacs). Configure mpdmacs to connect to your MPD server by customizing the variables:

  • mpdmacs-host & mpdmacs-port: If you’re talking over a TCP socket, configure these two variables with the hostname and port number at which MPD is listening
  • mpdmacs-socket: If your MPD server is local & listening on a Unix socket, set this variable to its path. If you want to talk over a TCP socket, best to set this to nil (mpdmacs-mode, below, will try the local socket first, if it exists)

At this point, mpdmacs has done nothing: you need to explicitly enable it by calling (mpdmacs-mode). This will open a connection to your MPD server, begin monitoring its state for changes, and enable you to begin issuing commands.

mpdmacs supplies several interactive commands, with keybindings in mpdmacs-mode-keymap; you may want to map a chord you find convenient to that keymap like so:

(defun my-mpdmacs-hook ()
  (global-set-key "\C-c m" 'mpdmacs-mode-keymap))
(add-hook 'mpdmacs-mode-hook 'my-mpdmacs-hook)

If you ever want to turn mpdmacs off, you can invoke (mpdmacs-mode) again.

Motivation & Philosophy

There are already capable MPD clients out there such as mpdel & mpc so why another? I’ve tried both & like them fine, but they’re full-featured MPD clients. I hope that mpdmacs will fill a different role, that of an unobtrusive assistant while you’re using Emacs for other things. If you want to, say, display & edit the current play queue, you would go to one of them. If you just want to skip to the next track with a quick key sequence while doing something else, use mpdmacs.

Learning More or Contributing

At the time of this writing, mpdmacs.el consists of a few hundred lines of code, so if you’re looking to customize or hack on it, dive in! Comments, complaints, suggestions & PRs welcome.

Status & Roadmap

Basic playback functionality is there, but that’s pretty much it except for a few other little features like adding the current song to the mode line.

About

mpdmacs is a lightweight, ergonomic MPD client for Emacs.

Resources

License

GPL-3.0, GPL-3.0 licenses found

Licenses found

GPL-3.0
LICENSE
GPL-3.0
COPYING

Stars

Watchers

Forks

Packages

No packages published

Languages