Skip to content

tusharwebd/taste-explorer

 
 

Repository files navigation

Taste Explorer

Compare your music preferences to your friends starting with the ability to create playlists that with just your music, just your friend's music, or music you've both loved.

wireframe

Development

Requirements

1 | Install Dependencies

npm install

2 | Configure Environment Variables

Create a .env file in the root directory.

cp .env.example .env

Update...

  • Spotify Client Id
  • Spotify Client Password
  • Last.fm API Key
  • Last.fm Shared Secret

Update the DATABASE_URL if you want to connect to a remote database.

3 | Run Web Server

npm run dev

4 | Run Cron Jobs

Start the cron jobs that track listening history and research additional information about tracks.

npx ts-node src/music/cron/scheduleJobs.cron.ts \
              updateListeningHistory \
              createListens \
              addTrackFeatures

Consider running these in separate screen instances.

Testing

Set Up Tests

  1. Create a .env.test.local file
cp .env.example .env.test.local
  1. Configure the DATABASE_URL to connect to the test database hosted by Docker
# Filename: .env.test.local
...
DATABASE_URL='mysql://root:test@localhost:3306/test'
...

Run Tests

npm run test

The Dockerized database for tests will start running and tests will be executed.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 82.3%
  • EJS 7.7%
  • JavaScript 6.4%
  • CSS 3.6%