5 releases (1 stable)
| 1.0.0 | Jan 27, 2026 |
|---|---|
| 0.3.1 | Jan 25, 2026 |
| 0.3.0 | Jan 25, 2026 |
| 0.2.1 | Jan 25, 2026 |
| 0.1.0 | Jan 25, 2026 |
#691 in Audio
460KB
3.5K
SLoC
Trix Player
A beautiful, keyboard-driven terminal music player for Linux.
Features • Installation • Usage • Building
Trix is a lightweight, high-performance music player built with Rust. It is designed for Linux users who prefer the terminal, offering a clean TUI (Terminal User Interface), robust keyboard navigation (vim-like), and low resource usage.
🎬 Demo
https://github.com/user-attachments/assets/4a7be924-2580-49d4-bd89-cddd8a084f2b
✨ Features
- Format Support: MP3, FLAC, WAV, OGG, M4A, AAC, Opus.
- Intuitive TUI: Clean interface built with
ratatui. - Volume Control: Native ALSA system volume control (with software fallback).
- Search: Fast, fuzzy-like filtering to find tracks instantly.
- Playback Control: Shuffle, Loop (track/playlist), and Seek.
- File Management: Delete tracks directly from the player.
- Standard Compliance: automatically detects music via
XDG_MUSIC_DIRor defaults to~/Music.
📦 Installation
Arch Linux (AUR)
Trix is available on the AUR as trix-player. Use your favorite AUR helper:
yay -S trix-player
# or
paru -S trix-player
Debian / Ubuntu
Download the latest .deb file from the Releases Page.
sudo dpkg -i trix-player_*.deb
sudo apt-get install -f # Fix dependencies if needed
Fedora / RHEL / openSUSE
Download the latest .rpm file from the Releases Page.
sudo rpm -i trix-player-*.rpm
Generic Linux (Binary)
Download the .tar.xz archive from the Releases page, extract it, and move the binary to your path.
tar -xf trix-player-*.tar.xz
sudo mv trix /usr/local/bin/
One-line Install (curl)
Installs the latest x86_64-unknown-linux-gnu release into ~/.local/bin (or /usr/local/bin if run as root).
curl -fsSL https://raw.githubusercontent.com/RIZAmohammadkhan/TerminalMusicPlayer/main/install.sh | sh
Install to a custom prefix:
curl -fsSL https://raw.githubusercontent.com/RIZAmohammadkhan/TerminalMusicPlayer/main/install.sh | PREFIX=/usr/local sh
From Source (Rust)
If you have the Rust toolchain installed:
git clone https://github.com/RIZAmohammadkhan/TerminalMusicPlayer.git
cd TerminalMusicPlayer
cargo install --path .
🚀 Usage
Run the player by typing:
trix
By default, Trix looks for music in your XDG Music directory (usually ~/Music). You can also play a specific directory or file:
trix /path/to/my/songs
⚙️ Configuration
Trix can load a user config file from:
$XDG_CONFIG_HOME/trix/config.toml- or (fallback)
~/.config/trix/config.toml
Currently this is focused on theming colors.
Theme selection is intentionally not terminal-specific:
- Default theme: Atom Dark accents (standardized RGB colors) with terminal-default background
- Override: your config file values (deterministic, field-by-field)
For maximum consistency across terminals, prefer hex RGB colors (e.g. "#61afef").
Basic named colors (e.g. "cyan", "white") may still vary depending on your terminal’s ANSI palette.
Theme colors
Color values can be basic names (e.g. "cyan", "dark_gray") or hex RGB (e.g. "#61afef").
Important semantic constraint:
theme.library_accentis used for both the Library frame and the selection highlight. This is intentional so you can't configure the UI into a confusing state where “library color” and “selection color” drift apart.
Example ~/.config/trix/config.toml:
[theme]
# Global UI background
# Use "reset" (or omit this key) to respect your terminal background/transparency.
# Set a hex color (e.g. "#282c34") to force a solid UI background.
background = "reset"
title_accent = "#61afef"
current_track_accent = "#56b6c2"
playing_indicator = "#98c379"
# Single knob: library frame + selection highlight
library_accent = "#e5c07b"
now_accent = "#61afef"
progress_accent = "#98c379"
hints_accent = "#c678dd"
search_accent = "#56b6c2"
move_accent = "#e5c07b"
key_accent = "#c678dd"
song_title_accent = "#e5c07b"
text_primary = "#abb2bf"
text_muted = "#5c6370"
error = "#e06c75"
Keyboard Controls
Trix is designed to be used entirely without a mouse.
| Key | Action |
|---|---|
| Navigation | |
↑ |
Move selection up |
↓ |
Move selection down |
Enter |
Play selected track |
PgUp / PgDn |
Scroll page up/down |
| Playback | |
Space |
Pause / Resume |
N |
Play next track |
P |
Play previous track |
l |
Toggle Loop (Current track) |
s |
Toggle Shuffle |
r |
Restart current track |
| Seeking | |
→ |
Seek forward 5s (per press) |
← |
Seek backward 5s (per press) |
n |
Seek forward 10s |
p |
Seek backward 10s |
| Utility | |
S |
Search mode (Type to filter, Enter to play) |
m |
Move to timestamp (e.g. 1:30, 01:02:03) |
v |
Volume mode (Use ↑/↓ to adjust, v/Esc to exit) |
F12 |
Hide/Unhide Trix (shell; press again to return, or exit) |
D |
Delete track (Press twice to confirm) |
h / ? |
Toggle Help / Cheatsheet |
q |
Quit |
🔧 Dependencies
To build or run Trix, you need ALSA development libraries installed on your system.
- Debian/Ubuntu:
sudo apt install libasound2-dev - Fedora:
sudo dnf install alsa-lib-devel - Arch:
sudo pacman -S alsa-lib
🤝 Contributing
Contributions are welcome! Feel free to open issues for bugs or feature requests.
- Fork the repository.
- Create your feature branch (
git checkout -b feature/AmazingFeature). - Commit your changes (
git commit -m 'Add some AmazingFeature'). - Push to the branch (
git push origin feature/AmazingFeature). - Open a Pull Request.
Known Bugs
- closing terminal results in 1 second lag of audio closure
- colors don't work properly need more standardization instead of terminal specific
📄 License
Distributed under the MIT License. See LICENSE for more information.
👤 Author
Riza Mohammad
- GitHub: @RIZAmohammadkhan
Dependencies
~16–49MB
~816K SLoC