deezer-datasync synchronizes user data from Deezer:
- Favorite albums
- Favorite artists
- List of playlists
- Individual playlists with their associated tracks
Current version is v0.6.1.
As of the current version, only GitHub is supported as a backend; the application will commit JSON files in this arborescence:
your-git-repo/
├── playlists/
│ ├── {id}_{title}.json
│ ├── {id}_{title}.json
│ ├── [...]
├── albums.json
├── artists.json
└── playlists.json
Using GitHub as a backend can seem peculiar, but it fits my needs very well: keeping a full history of my profile and easily check daily diffs, especially to make sure Deezer isn't altering my data.
See the changelog.
This project is mainly developed for my personal use and as such, is experimental. However I'll be glad to help if you encounter any issue.
You'll need a Deezer token to use this application. You can follow Deezer's instructions here. I have also written a documentation here.
It seems that Deezer has disabled the creation of 'apps':
We're not accepting new application creation at this time. Please check again later.
This means you can't create the token that this project needs to run. If you have a valid API token somewhere, it should work. At least my instance still runs for now. Not for long?
To use the application, you need to prepare a configuration file in HOCON format. An example file is provided in the source code, see application.conf.
A multiplatform image (AMD64 and ARMv7 -- for execution on a Raspberry Pi 3) is available on Dockerhub:
# Pull the latest version of the image
docker pull alecigne/deezer-datasync:latest
# Run the container with the latest image (check that your config file is compatible!)
docker run -it -v /absolute/path/to/application.conf:/application.conf alecigne/deezer-datasyncOnly the last stable version is available on Dockerhub (master branch).
Download a Jar in the releases section, then run it using Java 17:
java -Dconfig.file=/path/to/application.conf -jar deezer-datasync.jarOnly the stable versions are available as releases (master branch).
You probably know what you're doing anyway 🙂
Playlist filenames ({id}_{title}.json) are generated from "clean" playlist titles:
- The title is converted to lowercase.
- Any group of non-alphanumeric characters (size 1 or more) is converted to an underscore.
- Any trailing underscore is removed from the title.
You can see basic cases in issue #28. This issue was the basis for the parameterized test
in GitHubMapperTest.java. There is also a property-based test in
GitHubMapperPropertyTest.java.