Skip to content

Latest commit

 

History

History
27 lines (16 loc) · 876 Bytes

Readme.md

File metadata and controls

27 lines (16 loc) · 876 Bytes

RadioScrape

A super simple Ruby script to call the "Now Playing" service for a certain station and find out what is playing.

Getting Started

First you need to create and app at https://developer.spotify.com/my-applications/#!/applications. Set the callback to http://brooksgarrett.com/projects/radioscrap/callback.html. I don't log your tokens (it's pure HTML and javascript.)

Give the program your client ID and client secret to get your token link. Once you follow the link paste the code into the app and set debug to false.

You're ready to go!

Scrape.rb

ruby scrape.rb

I configure scrape to run from my cron every minute. Adjust as you like.

Playlist.rb

ruby playlist.rb

This command will generate your playlists. It will name the playlist after the station name.