Skip to content

danielhp02/spotify-lyrics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

149 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

spotify-lyrics

Gets current track from Spotify, gets the lyrics from Genius and outputs to a Flask app.

Dependencies

Set up

The following set up guide is written under the assumption that you are using a Unix based shell. If not, I highly recommend you get one. I use Ubuntu through WSL (Windows Subsystem for Linux).

Code adjustments

  • Change the username string on line 16 of ./spogen/lyrics.py to your Spotify username.

Console

Run sudo python3 setup.py install

Tokens

At the moment, tokens must be manually added. Support for oAuth 2.0 is planned to be implemented soon.

  • Duplicate ./tokens.dummy.json and rename it to tokens.json.
  • Go to the Spotify Developer Dashboard and log in.
  • Create a new app. Name it whatever, I called it spotify-lyrics. Set the redirect URI to http://localhost/
  • Now if you go into the app, you can get the client id and secret. You'll want to copy those into tokens.json. Also set your redirect URI in tokens.json to http://localhost/ as well.
  • Go to the Genius API Clients page and create an API client.
  • For the app name, again doesn't really matter, but you should name it the same as the Spotify one. Set the "App Website URL" to http://localhost/ or the Github page.
  • Copy the client access token into tokens.json.

Running the program

To run, use . ./init.sh. If everything is set up correctly, it should work.

If the lyrics are inaccurate or completely wrong, you can manually set them by clicking the "No" button under the album art. This will create a textbox in which you can enter lyrics. Newlines will automatically be converted into HTML friendly <br> tags. The changes made are saved to the database.

Known bugs

  • Beetlebum by Blur cannot be found even with name formatting, despite being on Genius.

About

Gets current track from Spotify and then gets the lyrics from Genius

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors