All Projects → christopher-dG → Gpymusic

christopher-dG / Gpymusic

Licence: mit
Google Py Music: A simple TUI client for Google Play Music

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Gpymusic

Mprislyrics
Small command-line utility that displays lyrics in sync with the currently playing song in a MPRIS2 capable player.
Stars: ✭ 24 (-88.24%)
Mutual labels:  command-line, music-player
Survey
A golang library for building interactive and accessible prompts with full support for windows and posix terminals.
Stars: ✭ 2,843 (+1293.63%)
Mutual labels:  command-line
Flutter Ui Kit
A repository full of beautiful UI examples in Flutter
Stars: ✭ 188 (-7.84%)
Mutual labels:  music-player
Sharprompt
Interactive command line interface toolkit for C#
Stars: ✭ 197 (-3.43%)
Mutual labels:  command-line
Multi Room Audio Centralized Audio For Home
🎵 This Github Repository provides details on setting up a centralized audio system for your home using nothing but Raspberry Pi's and Old Speakers.
Stars: ✭ 189 (-7.35%)
Mutual labels:  music-player
Zoxide
A smarter cd command. Supports all major shells.
Stars: ✭ 4,422 (+2067.65%)
Mutual labels:  command-line
Goaccess
GoAccess is a real-time web log analyzer and interactive viewer that runs in a terminal in *nix systems or through your browser.
Stars: ✭ 14,096 (+6809.8%)
Mutual labels:  command-line
Ascii
👾 ASCII Roulette :: ascii art video chat on the cli
Stars: ✭ 202 (-0.98%)
Mutual labels:  command-line
Askgit
Query git repositories with SQL. Generate reports, perform status checks, analyze codebases. 🔍 📊
Stars: ✭ 2,707 (+1226.96%)
Mutual labels:  command-line
Vue Musicapp
使用vue全家桶制作的音乐播放器
Stars: ✭ 195 (-4.41%)
Mutual labels:  music-player
Facebash
Facebook Brute Forcer in shellscript using TOR
Stars: ✭ 195 (-4.41%)
Mutual labels:  command-line
Sudo Productivity
Boost your "productivity" to the max! A fun project made for slackers by slackers.
Stars: ✭ 190 (-6.86%)
Mutual labels:  command-line
Winfetch
🛠 A command-line system information utility written in PowerShell. Like Neofetch, but for Windows.
Stars: ✭ 189 (-7.35%)
Mutual labels:  command-line
Gcli
🖥 Go CLI application, tool library, running CLI commands, support console color, user interaction, progress display, data formatting display, generate bash/zsh completion add more features. Go的命令行应用,工具库,运行CLI命令,支持命令行色彩,用户交互,进度显示,数据格式化显示,生成bash/zsh命令补全脚本
Stars: ✭ 188 (-7.84%)
Mutual labels:  command-line
Gpustat
📊 A simple command-line utility for querying and monitoring GPU status
Stars: ✭ 2,662 (+1204.9%)
Mutual labels:  command-line
Aconfig
Simple, useful and opinionated config loader.
Stars: ✭ 187 (-8.33%)
Mutual labels:  command-line
Tq
Perform a lookup by CSS selector on an HTML input
Stars: ✭ 193 (-5.39%)
Mutual labels:  command-line
Nighthawk
A stealthy, simple, unobtrusive music player that stays out of your way
Stars: ✭ 197 (-3.43%)
Mutual labels:  music-player
Saldl
A lightweight well-featured CLI downloader optimized for speed and early preview.
Stars: ✭ 203 (-0.49%)
Mutual labels:  command-line
Miniserve
🌟 For when you really just want to serve some files over HTTP right now!
Stars: ✭ 2,894 (+1318.63%)
Mutual labels:  command-line

Google Py Music

PyPI

A simple TUI client for Google Play Music

Browse and stream Google Play Music from the comfort and familiarity of your favourite terminal.

screencast

Disclaimer

Google Py Music is essentiallly unmaintained; I'll address security alerts and review PRs but I won't be fixing bugs or adding anything new myself.

These days I use Spotify with spotifyd and baton. For GPM, I recommend tuijam, which has loads more features and is actively maintained!

Dependencies

All of these can usually be installed with your operating system's package manager.

Installation

The easiest way to install is with pip by running pip3 install gpymusic.

You can also install from source:

$ git clone https://github.com/christopher-dG/gpymusic
$ cd gpymusic
$ python setup.py install

A special thanks goes to ftxrc for his work on the pip installation.

Configuration

Once gpymusic is installed, run gpymusic-setup. An example config file will be placed in ~/.config/gpymusic. Additionally, you should run gpymusic-oauth-login and follow the prompts if you have a free account.

Device ID

If you don't know your device ID, run gpymusic-get-dev-id and follow the prompts to generate a list of valid device IDs.

Password

You can choose to leave the password field empty and you will be prompted for it upon starting the program. Otherwise, you can supply it for automatic logins.

If you store your password in plain text, be aware the potential consequences.

Colours

Colour themes are defined in the colour section of your config file. To enable colour, make sure enable is set to yes and set the fields to hex colours as desired. highlight affects the section headers and 'now playing' output, content{1|2} affect the main window, and background/foreground are self-explanatory.

Setting background to default allows you to use your terminal background colour, which means this allows transparency if your terminal supports it.

Note: Upon exiting the program, your terminal colours will likely be modified. Just open a new terminal session and your colours will be back to normal.

Now Playing

To log the currently playing track to a file, include a nowplaying section in your config file with enable set to yes. A filename may then be specified, or the default value of ~/.nowplaying will be used.

This file may then be used in status bars or simple notifications systems. For example, here is a simple i3blocks definition:

[music]
command=cat ~/.nowplaying
interval=5

Running Google Py Music

Once installed and configured, the program can be run from the terminal with gpymusic. While the program is running, don't resize your terminal.

Controls

  • s/search search-term: Search for search-term
  • e/expand 123: Expand item number 123
  • p/play: Play the current queue
  • p/play s: Shuffle and play the current queue
  • p/play 123: Play item number 123
  • q/queue: Show the current queue
  • q/queue 123: Add item number 123 to queue
  • q/queue 1 2 3: Add items 1, 2, and 3 to the queue
  • q/queue c: Clear the current queue
  • radio 123: Create radio station around item number 123
  • w/write playlist-name: Write the current queue to playlist playlist-name
  • r/restore playlist-name: Replace the current queue with a playlist from file-name
  • h/help: Show help message
  • Ctrl-C: Exit Google Py Music

When playing music:

  • spc: Play/pause
  • 9/0: Volume down/up (Note: volume changes are not persistent across songs, so I recommend that you adjust your system volume instead)
  • n: Next track
  • q: Stop
  • ↑/↓/←/→: Seek

Accounts

Google Py Music works similarly to the web interface in that users with free accounts can only arbitrarily access music that they've purchased or uploaded, whereas users with paid accounts can search for and stream anything. When playing music with a free account, the entire song is downloaded and played locally rather than streamed.

Notes for free users:

  • OAuth2 login is required for free users, make sure you've run gpymusic-oauth-login as described in configuration!
  • If you don't want to wait for songs to download on the fly, you can download them all in one go by running gpymusic-download-all. Songs are stored in ~/.local/share/gpymusic/songs.
  • The e/expand command does not work for free users because artists and albums cannot be generated, so there is nothing for it to do.
  • I don't have enough music uploaded to my free account to properly test it, so please open issues about any crashes or other problems.

2-Factor Authentication

If your account has 2FA set up, you will need to use an app password to log in. If you're storing your password in your config file, replace it with the app password.

Crashes

If gpymusic crashes, your terminal settings will likely be messed up, in which case stty sane will restore order. Don't forget to open an issue!


Thanks for using Google Py Music!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].