Quidest?

moc-mpris-bridge

moc-mpris-bridge

A lightweight D-Bus bridge that implements the MPRIS (MediaPlayer2) interface for MOC (Music on Console).

This allows MOC to integrate with desktop environments and media controllers that use the standard MPRIS protocol — enabling media key support, playback info in status bars, and control through tools like playerctl.

Features

Requirements

Installation

From AUR

1yay -S moc-mpris-bridge

From source

1go install github.com/azre1/moc-mpris-bridge@latest

Or clone and build manually:

1git clone https://github.com/azre1/moc-mpris-bridge.git
2cd moc-mpris-bridge
3go build -o moc-mpris-bridge .

From releases

Pre-built binaries for linux/amd64 and linux/arm64 are available on the GitHub Releases page.

Usage

Start the bridge directly:

1moc-mpris-bridge

Systemd service

Copy the service file and enable it as a user service:

1sudo cp moc-mpris-bridge /usr/bin/
2cp moc-mpris-bridge.service ~/.config/systemd/user/
3systemctl --user enable --now moc-mpris-bridge

The service will automatically restart if it exits, and starts after D-Bus is available.

The service file is available immediately if installing from AUR.

How it works

The bridge polls MOC’s status once per second via mocp -i and exposes the state over D-Bus under the name org.mpris.MediaPlayer2.moc-mpris-bridge. It implements both the org.mpris.MediaPlayer2 and org.mpris.MediaPlayer2.Player interfaces, so any MPRIS-aware client can discover and control MOC.

TODO