Skip to content
 
 

Repository files navigation

myx

A lean, beautiful terminal Spotify player in Rust. Streams natively as a Spotify Connect device, with album-art-reactive theming, a live audio visualizer, a ten-band equalizer, and synced lyrics.

Myx.mp4

Requires Spotify Premium. Works on Linux, macOS, and Windows. Album art is crispest on kitty, WezTerm, or foot.

Install

# Arch (AUR)
yay -S myx

# macOS / Linux (Homebrew)
brew install HaseebKhalid1507/homebrew-tap/myx

# Cargo (all platforms — Linux, macOS, Windows)
cargo install myx

# Prebuilt binary (Linux x86_64, macOS)
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/HaseebKhalid1507/Myx/releases/latest/download/myx-installer.sh | sh

On Windows, install Rust first, then cargo install myx in PowerShell. Set MYX_CLIENT_ID as an environment variable or place your client ID in %USERPROFILE%\.config\myx\client_id.

Or grab a .deb / archive from Releases, or build from source: cargo install --path ..

Get started

You need a free Spotify app client ID (one minute):

  1. Spotify developer dashboard, then Create app
  2. Add the redirect URI http://127.0.0.1:8989/login
  3. Copy the Client ID and set it:
export MYX_CLIENT_ID=<your-client-id>

Then run:

myx

First launch opens your browser to log in (OAuth PKCE, no secret needed). Then browse with ↑↓ and hit to play. After that, just myx.

Keys

← → / [ ]  switch section        ⇥        library ⇄ queue
↑↓ / j k   move                  ⏎        play / open
⇧ ⏎        play the highlighted album, playlist or artist
l          lyrics                a        actions
/          search                space    play · pause
⇧ ← →      seek                  n / b    next · prev
+ / -      volume                s        shuffle
o          sort                  R        repeat
z          hide sidebar          r        reload
e          equalizer             q        quit

moves the keyboard between the library sidebar and the queue, from any view — the queue then takes ↑↓ / j k, and plays from the highlighted track onward. Esc (or again) hands the keyboard back and restores the view you were on. On wide terminals the queue is already beside Now Playing; on narrower ones brings it up.

Media keys (Play/Pause, Stop, Next, Prev, Volume) work when the terminal is focused. On macOS and Linux, AirPods and headphone controls work from anywhere via the system's Now Playing integration. Mouse works too: click tabs, click a track, double-click to play.

Equalizer

Press e for the live ten-band equalizer. Choose Flat, Bass Boost, Rock, Jazz, Vocal, Electronic or Treble Boost with Tab / Shift+Tab; changing a band creates a Custom curve. Use / to choose a band, / to adjust it, Space to compare against bypass, and Esc to close. Presets and sliders are also clickable and draggable. Automatic headroom keeps boosted curves from digitally clipping, and the complete curve is restored on the next launch.

Holding ⇧ ← / ⇧ → scrubs continuously and commits one seek when you let go. ⇧ ⏎ needs a terminal that reports modified Enter (kitty, WezTerm, foot); P does the same everywhere.

The album-art protocol is detected at startup and picked per terminal, including inside tmux. If your tmux has no sixel support, add set -g focus-events on to ~/.tmux.conf so the art is re-sent when you switch back to myx's window.

Config

~/.config/myx/config.toml is written on first run with every key commented out, so there is a file to edit and nothing to look up:

# Rows kept visible above and below the cursor before the list scrolls.
scrolloff = 3

# Resume the locally saved track, source and position when Myx starts.
restore_on_startup = true

# Spotify app client id. MYX_CLIENT_ID overrides this if it is set.
client_id = "your-client-id"

# kitty, iterm2, sixel or halfblocks. Leave it out to auto-detect; set it if
# album art comes out as a coarse mosaic, which means the terminal never
# answered the detection query. MYX_PROTOCOL overrides this.
protocol = "kitty"

Credits

Streaming adapts pieces of spotify-player (MIT, © Thang Pham); visual language after noodle; built on ratatui and librespot. See NOTICE.

License

MIT, see LICENSE.

About

Spotify player for the terminal. With reactive themes.

Resources

Contributing

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages