TuMusic

A small program written in Go that lets you play music from the command line. It uses FFmpeg to play audio and was built using an ELM architecture.

✕ Close

Project README

🎵 TuMusic

A lightweight terminal music player for YouTube songs, built with Go.

Features

  • Search and download songs
  • Play songs directly from the terminal
  • Pause and resume playback

Dependencies

Configuration

YouTube Data API v3

TuMusic uses the YouTube Data API to search for songs. You need to create an API key:

  1. Go to Google Cloud Console
  2. Create a new project
  3. Enable YouTube Data API v3
  4. Create credentials → API Key
  5. Create a .env file in the root of the project:
YOUTUBE_API_KEY = your_api_key_here

Installation

1. Install ffmpeg

Windows:

winget install ffmpeg

Linux:

sudo apt install ffmpeg

Mac:

brew install ffmpeg

2. Clone and run

git clone https://github.com/nestorgonate/tumusic.git
cd tumusic
go run .

Or build the binary:

go build -o tumusic.exe .
./tumusic.exe

Usage

  1. Select Add song to search and download a song
  2. Select Play songs to browse your downloaded songs
  3. Use arrow keys to navigate and Enter to select
  4. Use Pause/Resume or Stop to control playback
  5. Press Esc to go back, Ctrl+C to exit

License

MIT

← Back to Explore