losnoco / Cog

Cog - A Free and Open Source Audio Player for macOS 10.13+
https://cog.losno.co
GNU General Public License v2.0
666 stars 45 forks source link

Import iTunes/Apple Music Library #219

Open tambourine-man opened 2 years ago

tambourine-man commented 2 years ago

Sorry, but I couldn't find this information anywhere.

Cog seems to be exactly whats I've been hoping for after Apple's change of direction in the last decade regarding iTunes.

However, I have over 20 years of metadata (play counts, date added, last played, stars, etc) that I don't want to loose.

Is it possible to import iTunes/Apple Music Library.xml into Cog?

Thanks

kode54 commented 2 years ago

I'll look into it, but it will probably be quite a chore to deal with. I'm not sure if Apple makes the APIs public. I'll also have to add play counts to my data storage and play control. Probably after a total of 90 seconds or full file duration, whichever is shortest, will increment the count. I'll also have to store the play count separately from the track data, since track data currently reference counts based on whether the tracks are in the playlist or not.

tambourine-man commented 2 years ago

Apple Music and iTunes are both able to export the entire library in XML (play lists, play counts, stars, etc). It should be a lot of work for sure, but at least there's no need for private API reverse engineering. Thanks

kode54 commented 2 years ago

Well, here's the thing, that should be useful for manual intervention style importing, but there are public APIs for accessing the database, I think. Or at least, that's what XLD seems to do for reading imported CDs' tags. I'll look into the XML thing eventually.

kode54 commented 2 years ago

I can try importing folder paths, but I'll never be able to support Apple Music streaming, and not the encrypted downloads, either.

tambourine-man commented 2 years ago

I use Apple Music/iTunes the old fashion way, to listen to MP3s stored on folders on my Mac. I, for one, couldn't care less for streaming or encrypted files.

I just wanted metadata like, last played, play counts, etc. But I don't know if there's demand for that among Cog users.