Search and play songs right from your terminal!
- youtube-dl
- ffmpeg (This program currently uses the
ffplayutility to play audio)
- Get API key for the Youtube API by creating a new project here and then generate credentials
- Install youtube-dl and ffmpeg
- [For Windows] Add
youtube-dl.exeandffplay.exeto the path - Download the binary from the releases section of this repository
- [For Linux] Make the binary executable
- [For Windows] Add the binary to the path to execute from anywhere
- List all available flags
ytplay -horytplay --help - Run
ytplay -key <your-api-key>(API key needs to be set in order to search for songs from YouTube) - Then just search for songs by keyword
ytplay search <keyword>(Make sure there are no spaces in the keyword) - Ctrl+C is used for pausing/stopping the song
- A song stopped with ^C can be resumed by typing
ytplay -resume
- The Youtube API has a default quota of 10k units per day
- Each search request consumes 100 units
- That means you can search for 100 songs per day and the quota will be reset for the next day
- Tests
- Creating and managing playlists
- Use a Go audio libary like faiface/beep or oto (remove ffplay dependency)
- Improve UI by using TUI libs