Skip to content
This repository has been archived by the owner on Aug 15, 2024. It is now read-only.
/ admirer Public archive

๐Ÿ”„ ๐ŸŽถ Sync loved tracks between music services.

License

Notifications You must be signed in to change notification settings

dietrichm/admirer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Admirer

Go version Go CI License Go Reference

A command line utility to sync loved tracks between music services.

Installation

Compiled binaries will be provided for version 1.0.0.

Note: Admirer is currently only tested on Linux.

Building from source

Please install Go 1.20 first, set the GOPATH environment variable and ensure $GOPATH/bin is present in $PATH.

go install github.com/dietrichm/admirer@latest

Usage

Usage:
  admirer [command]

Available Commands:
  completion  Generate the autocompletion script for the specified shell
  help        Help about any command
  list        List loved tracks on specified service
  login       Log in on external service
  status      Retrieve status for services
  sync        Sync recently loved tracks from one service to another

Flags:
  -h, --help   help for admirer

Use "admirer [command] --help" for more information about a command.

Supported services

Last.fm and Spotify have an initial implementation.

In the future, I would like to add support for ListenBrainz and CSV/JSON files as well (#27).

Authentication

Before using any of the provided services, you need to create your own API application on said service and export your new API client ID and secret as environment variables:

Service Creating your app Environment variables
Last.fm Create an account here LASTFM_CLIENT_ID and LASTFM_CLIENT_SECRET
Spotify Manage and create an app here SPOTIFY_CLIENT_ID and SPOTIFY_CLIENT_SECRET

When this is done, continue with the following steps.

  1. Run admirer login <service> to retrieve an authentication URL.
  2. By visiting this URL, the service will ask confirmation and redirect back to a non existing URL https://admirer.test/....
  3. Copy and paste the desired query parameter from the URL into the CLI input and press Enter.
  4. If all goes well, you will retrieve confirmation that you have been logged in.

Note 1: after #23, API client IDs and secrets will be queried during login and stored along with other authentication secrets.

Note 2: #25 will add an internal HTTP server to retrieve the authentication callback automatically.

Use cases

Listing recently loved or added tracks

Using the list command, you can retrieve a list of your most recently loved or added tracks on said service.

Syncing recently loved tracks between services

Using the sync command, you can synchronise recently loved tracks from one service to another. For example to mark as loved on Last.fm the same tracks that were added to your library on Spotify, or vice versa.

License

Copyright 2020, Dietrich Moerman.

Released under the terms of the MIT License.

About

๐Ÿ”„ ๐ŸŽถ Sync loved tracks between music services.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published