Socket
Book a DemoInstallSign in
Socket

music_compare

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

music_compare

0.1.0
bundlerRubygems
Version published
Maintainers
1
Created
Source

MusicCompare

With this gem you can:

  • fetch public playlists from spotify into .csv files
  • compare two .csv playlist files for matches

Installation

Add this line to your application's Gemfile:

gem 'music_compare'

And then execute:

$ bundle install

Or install it yourself as:

$ gem install music_compare

Usage

First you need to specify 'client_id' and 'client_secret', you can do this in .env file or when you create an object:

compare = MusicCompare::Compare.new('client_id', 'client_secret')

Fetch playlists

To fetch playlists from spotify you need playlists id's, for example:

  • https://open.spotify.com/playlist/1Iddrohefgh7PJgNjL9Kmp
  • https://open.spotify.com/playlist/1Iddrohefgh7PJgNjL9Kmp?si=0898cf7f075443e9&nd=1
playlists = ['1Iddrohefgh7PJgNjL9Kmp', '7r88KVwegNkxSl36zrhx30']
compare.fetch_playlists!(playlists)

also you can specify directory path, where you want to store you playlists:

compare.fetch_playlists!(playlists, dir_path: 'home/username/')

Compare playlists

compare.compare('1Iddrohefgh7PJgNjL9Kmp', '7r88KVwegNkxSl36zrhx30')

or with directory path:

compare.compare('1Iddrohefgh7PJgNjL9Kmp', '7r88KVwegNkxSl36zrhx30', dir_path: 'home/username')

FAQs

Package last updated on 02 Aug 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.