Skip to content

Repository files navigation

Firefly, Terminal Audio Player

Written in Rust with audio playback handled by Rodio and UI built with Ratatui. example_img (Showcase as of v0.10.0, using Kitty with Atelier Dune Dark theme.)

Features (v0.13.1)

  • Play, Pause, Rewind, and Seek.
  • Persistent Playlists
  • Volume Control from 0-200%
  • Track Looping
  • Pick Files from File Dialog or Command-Line Argument.
  • Track and Directory queuing
  • Queue Arrangement, Shuffling, Clearing
  • Save Queue as Playlist.
  • Skip Forward or Backward
  • Metadata Display
  • [Linux] MPRIS Support: Media control with metadata, including cover art. KDE Connect compatible.

Formats Supported

It can still play other formats by converting formats not supported by Rodio to FLAC using rust_ffmpeg.

Temporary FLAC files stay on disk for reuse, which can be cleared by running firefly clean

Roadmap - open to suggestions

  • Playlists (v0.6.0)
  • Album art display for supported terminals (v0.7.0)
  • UI overhaul (v0.7.0)
  • Proper MPRIS control (v0.11.0)
  • A special session where you can control an existing session (queue tracks, etc.). [OUT OF SCOPE]

Installation

Windows and Linux

Download a Prebuilt Binary or use cargo binstall to automatically install it for you (requires cargo):

# Install cargo-binstall if not already
cargo install cargo-binstall
# Install firefly
cargo binstall firefly_music
# Launch the app
firefly

Optional Dependencies

  • FFmpeg - if you want to play unsupported file types.

Build from source

Fedora Linux

Dependencies

# Install dependencies
sudo dnf install wayland-devel alsa-lib-devel rust opus-devel cargo git
# Clone the repository
git clone https://github.com/ilialyl/firefly && cd firefly
# Build and run (optimized)
cargo run --release

CLI Examples

# Launch with a single file or directory
firefly with example.mp3
firefly with music/
# Launch with multiple files or directories
firefly with example.mp3 music/
# Launch with multiple files using [wildcards](https://www.malikbrowne.com/blog/a-beginners-guide-glob-patterns/.) (Only on Bash and Z shell)
shopt -s globstar # enable globstar
firefly with ./**/*.opus

Known Issue

  • Loading an OPUS track can be slow for files with large cover art (i.e. 1000x1000).
  • Wezterm (Windows) does not display cover art.
  • Does not work with WSL as no audio output is connected.

Bug Report

If you find any bugs, you can open an issue. I will get to it as soon as possible.

About

Linux-first TUI music player supporting FLAC, Opus, MP3, and WAV.

Resources

Code of conduct

Stars

9 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages