Skip to main content

A lightweight terminal music player with a pulsing Cthulhu

Project description

CLI Music Player

A lightweight, terminal-based music player written in Python, using mpv as the playback engine.

Demo

Features

  • Terminal User Interface (TUI): Clean interface built with curses.
  • File Browser: Navigate directories to find your music.
  • Recursive Library Mode: Scan all subdirectories and play your entire collection at once.
  • Shuffle Mode: Randomized playback with a history-aware "Previous" function.
  • Audio Formats: Supports mp3, wav, flac, ogg, m4a, wma, aac, opus.
  • Playback Controls:
    • Play / Pause / Stop
    • Next / Previous Track
    • Volume Control (up to 200%)
    • Seek / Progress Bar
  • Now Playing View: Dedicated screen showing track info and progress.
  • Dependency Check: Automatically detects and attempts to install mpv if missing (Linux).

Requirements

  • Python 3
  • mpv (The script attempts to install it automatically on Linux, but you can install it manually via your package manager).

Installation

  1. Clone the repository:

    git clone https://github.com/thiagofmendonca/cli-music-player.git
    cd cli-music-player
    
  2. Make the script executable:

    chmod +x musicplayer.py
    
  3. (Optional) Install globally:

    sudo cp musicplayer.py /usr/local/bin/musicplayer
    

Usage

Run the script from your terminal:

./musicplayer.py
# OR if installed globally:
musicplayer

Controls

Key Action
Arrow Up/Down Navigate files
Enter Play file / Open directory
Space Play / Pause
n Next Track
p Previous Track (History-aware in Shuffle)
z Toggle Shuffle Mode
R (Shift+r) Load Recursive Library (all subfolders)
B (Shift+b) Return to Browser Mode
+ / - Volume Up / Down
Tab Toggle "Now Playing" View
s Stop
q Quit (or go back from Player View)

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cli_music_player_cthulhu-0.3.1.tar.gz (11.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cli_music_player_cthulhu-0.3.1-py3-none-any.whl (11.3 kB view details)

Uploaded Python 3

File details

Details for the file cli_music_player_cthulhu-0.3.1.tar.gz.

File metadata

  • Download URL: cli_music_player_cthulhu-0.3.1.tar.gz
  • Upload date:
  • Size: 11.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for cli_music_player_cthulhu-0.3.1.tar.gz
Algorithm Hash digest
SHA256 c9d14651790f34a9542aafd77e27a8c52f16e76c69688604ff349165f5b2625e
MD5 a151a3adbb59aedc5ea399dbacdfdbb7
BLAKE2b-256 1a1867bae84e69d03dfb5c0b5bbbb9c33ac9e5ecbda86f956fdb02aca0ea8d44

See more details on using hashes here.

File details

Details for the file cli_music_player_cthulhu-0.3.1-py3-none-any.whl.

File metadata

File hashes

Hashes for cli_music_player_cthulhu-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0d771c5dbd6af47f7f58fcddaae6fb8653255d2a6671e2fb43452b07d102944f
MD5 8dc27f2517519abc25b8cf120d8807d2
BLAKE2b-256 4981f9ddc33b34f99b8c71ba9e505cdb46f015803426bba9a86778d634ab2b55

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page