Skip to main content

A command-line music application for coders with daemon support, radio streaming, and AI-generated music

Project description

music-cli

PyPI version Python 3.9+ License: MIT

A command-line music player for coders. Background daemon with radio streaming, local MP3s, and AI-generated music.

music-cli play --mood focus    # Start focus music
music-cli pause                # Pause for meeting
music-cli resume               # Back to coding

Installation

# Install from PyPI
pip install coder-music-cli

# Or with uv (faster)
uv pip install coder-music-cli

# Install FFmpeg (required)
brew install ffmpeg      # macOS
sudo apt install ffmpeg  # Ubuntu/Debian

Optional: AI Music Generation

pip install 'coder-music-cli[ai]'  # ~5GB (PyTorch + MusicGen)

Features

  • Daemon-based - Persistent background playback
  • Multiple sources - Local files, radio streams, AI generation
  • Context-aware - Selects music based on time of day and mood
  • Simple config - Human-readable text files

Quick Start

# Play
music-cli play                    # Context-aware radio
music-cli play --mood focus       # Focus music
music-cli play -m local --auto    # Shuffle local library

# Control
music-cli pause | resume | stop | status

Commands

Command Description
play Start playing (radio/local/ai/history)
stop / pause / resume Playback control
status Current track and state
next Skip track (auto-play mode)
volume [0-100] Get/set volume
radios List stations
history Playback log
moods Available mood tags
daemon start|stop|status Daemon control

Play Modes

# Radio (default)
music-cli play                     # Time-based selection
music-cli play -s "deep house"     # By station name
music-cli play --mood focus        # By mood

# Local
music-cli play -m local -s song.mp3
music-cli play -m local --auto     # Shuffle

# AI (requires [ai] extras)
music-cli play -m ai --mood happy -d 60

# History
music-cli play -m history -i 3     # Replay item #3

Moods

focus happy sad excited relaxed energetic melancholic peaceful

Configuration

Files in ~/.config/music-cli/:

File Purpose
config.toml Settings
radios.txt Station URLs
history.jsonl Play history

Add stations to radios.txt:

ChillHop|https://streams.example.com/chillhop.mp3
Jazz FM|https://streams.example.com/jazz.mp3

Documentation

Document Description
User Guide Complete usage instructions
Architecture System design and diagrams
Development Contributing guide

Requirements

  • Python 3.9+
  • FFmpeg

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

coder_music_cli-0.1.0.tar.gz (25.1 kB view details)

Uploaded Source

Built Distribution

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

coder_music_cli-0.1.0-py3-none-any.whl (27.3 kB view details)

Uploaded Python 3

File details

Details for the file coder_music_cli-0.1.0.tar.gz.

File metadata

  • Download URL: coder_music_cli-0.1.0.tar.gz
  • Upload date:
  • Size: 25.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for coder_music_cli-0.1.0.tar.gz
Algorithm Hash digest
SHA256 430765d7ceb22f6b50f65da080fd36eb6b1d599e8c3d45f91facae9472fc12ce
MD5 8a4fb86e1a1d53b8ab08471c6943bc10
BLAKE2b-256 18be24c94ee0db2b92be930600ba7dfc02b8e2ef8732468b245a4c317498d8da

See more details on using hashes here.

File details

Details for the file coder_music_cli-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for coder_music_cli-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 84009107ef72acca5d31ed60f175a90d43315d6c812f79e76f72fc2a5ae4e98e
MD5 2f50d04f32285c7deac3b26f163bed59
BLAKE2b-256 649612db7fc640f7a6b16763ae0e5a37d186c55b70f96c4c81f88dc46175623c

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