Grooveshark in your terminal.
Uses socket.io to pass messages back and forth between an open Grooveshark instance in Google Chrome and your terminal. In order to achieve this, an instance of a socket.io server is spawned as a daemon, serving as the middle-ware between the Chrome Extension and the CLI client.
Don't limit controlling Grooveshark to just your terminal! You can use any client to connect to the socket.io server to pass commands to Grooveshark (Android app, iOS app, etc).
Install with npm:
npm install -g grooveshark-cli
git clone firstname.lastname@example.org:L1fescape/grooveshark-cli-chrome.git
Load the Chrome Extension:
Load Unpacked Extension
- Navigate to where you cloned the Grooveshark CLI Chrome Extension repo
// start the servergrooveshark start-server// restore previous queuegrooveshark restore// show the queuegrooveshark queue//=> Number of Songs: 4//=>//=> 1. Lower Your Eyelids to Die With the Sun by M83//=> > 2. Midnight City by M83//=> 3. Moonchild by M83//=> 4. Soon, My Friend by M83// play current songgrooveshark play// get the status of the playergrooveshark status//=> Playing 00:02 / 04:04//=> Artist: M83//=> Song: Midnight City// stop playinggrooveshark stop// kill the servergrooveshark stop-server
Starts the server component as a daemon if it's not running already.
WARNING: Currently doesn't work. Kill with
ps ax | grep node; kill -9 [process id]. Super sorry, can't find a way to kill a forever daemon right now.
Stops the server daemon if it's currently running.
grooveshark play [song index]
Starts playing a song or resumes playback. If an index in the queue is included, play song at that index.
Pauses currently playing song.
Plays next song in queue if there is one.
Plays previous song in queue if there is one.
grooveshark vol [volume level]
Sets the volume level of the player (0-100)
Clears current queue.
Restores previous queue if there is one to restore.
- Find a better way to start and stop the socket.io server. Currently no way to detect if it is already running or not.
stop-serveractually do what it's supposed to do.
- Status can accept a format string that returns the status of the player in the format passed in.
- Document Server API so it's easier for people to write clients to connect and use it.
If there's an issue with the Chrome Extension, open an issue in the Grooveshark CLI Chrome Extension repo.
All feedback and suggestions welcome.
MIT License • © Andrew Kennedy