#midi #music #smf

app plmidi

Play MIDI files from the command line

15 releases (5 breaking)

0.14.2 Jun 16, 2022
0.13.1 Jun 11, 2022
0.9.6 Mar 7, 2022
0.9.4 Dec 22, 2021
0.9.3 Oct 18, 2021

#154 in Audio

Download history 74/week @ 2023-02-09 63/week @ 2023-02-16 13/week @ 2023-02-23 1/week @ 2023-03-16 22/week @ 2023-04-06 17/week @ 2023-04-13 1/week @ 2023-04-27 30/week @ 2023-05-04 5/week @ 2023-05-11 2/week @ 2023-05-18 15/week @ 2023-05-25

53 downloads per month

MIT and maybe LGPL-2.1

671 lines


A command line MIDI player with an embedded synthesizer.


Windows: With Scoop

First add my bucket to scoop:
scoop bucket add insomnia https://github.com/inssomnimus/scoop-bucket

Update scoop:
scoop update

Install the app:
scoop install plmidi

Download a pre-built release binary

Grab a binary for your platform from the releases page.

BYOB: Build Your Own Binary

Feature Flags

  • --features=system: Enable playback through MIDI out devices registered on the system.
  • --features=system-jack: Same with system but uses the Jack backend.
  • --features=winrt: Same with system except it uses the WinRT backend. Note that currently WinRT does not recognize OmniMidi or Virtual Midi Synth so I wouldn't recommend it.
  • --features=fluid: Enable fluidlite as a built-in MIDI synthesizer (requires libfluidlite and pkg-config to be present on your system).
  • --features=fluid-bundled: Enable fluidlite as a built-in MIDI synthesizer; use the bundled library. This feature is enabled by default.

You need an up to date rust toolchain installed.

On *NIX systems, you also need alsa development libraries:

# Debian and derivatives
apt install libasound2-dev

# RHEL and derivatives
dnf install alsa-lib-devel

To use the jack backend, you also need jack development libraries:

# Debian and derivatives
apt install libjack-jackd2-dev
# RHEL and derivatives
dnf install jack-audio-connection-kit-devel

You can install from crates.io: cargo install plmidi --features system

Or, you can clone it:

# to install after a git clone
git clone https://github.com/insomnimus/plmidi
cd plmidi
git checkout main
cargo install --path .
# To enable the system apis via the `jack` backend:
cargo install --path . --features system-jack
# To disable built-in fluidsynth support:
cargo install --path . --features system --no-default-features


  • plmidi foo.mid
  • (If the system feature is enabled) plmidi --device 2 foo.mid
  • (If the fluid feature is enabled) plmidi --fluidsynth ~/soundfonts/some-soundfont.sf2 foo.mid


~626K SLoC