Turn your Spotify playlist into a cache.
For people, who like me, have playlists with 100s of tracks in them (and growing!) but only listen to a small percentage of them.
Instead of your playlists growing out of control you can now set the max number of tracks in a playlist so as you add new tracks, older tracks will be removed.
Currently the only cache implemented is FIFO (First In First Out).
The hope is Spotify will eventually add a play count or last played to tracks in a playlist so a LRU (Least Recently Used) or LFU (Least Frequently Used) cache can be implemented.
Requires NodeJS & NPM.
Once installed, clone the repository and install its dependencies running.
Server:
$ cd server
$ npm install
Client:
$ cd client
$ npm install
Go to My Applications on Spotify Developer and create your application. Register this Redirect URI:
Once you have your your application credentials, create .env
with the following:
SPOTIFY_CLIENT_ID=<SPOTIFY_CLIENT_ID_GOES_HERE>
SPOTIFY_CLIENT_SECRET=<SPOTIFY_CLIENT_SECRET_GOES_HERE>
SPOTIFY_REDIRECT_URI=<SPOTIFY_REDIRECT_URI_GOES_HERE>
MONGO_URI=<MONGO_URI_GOES_HERE>
COOKIE_KEY=<COOKIE_KEY_GOES_HERE>
Then run:
$ npm run dev
For ESLint run:
$ npm run lint
For Mocha tests run:
$ npm run test
To build the client:
$ cd client
$ npm run build
Want to become a Cachify contributor? Then checkout our code of conduct and contributing guidelines.
Copyright (c) 2019 Conor Hughes - Released under the MIT license.