Hey everyone!
I am sitting here, importing music across from my laptop to my homeserver,
using iTunes. But when I got the songs from a friend, they accidentially got
imported as duplicates... So now I have things like this in my plist:
TrackID: 2222 {
Name: This Song
Artist: This Artist
File: .../This Song.mp3
}
TrackID: 2223 {
Name: This Song
Artist: This Artist
File: .../This Song 2.mp3
}
That is plain annoying! I have the rough idea on how to get rid of this. But -
before making something stupid, I wanted to ask for your opinion. Also keep in
midn that the database file is a bunch of MBs big (about 50k songs)
- Read the whole plist into an object
- Iterate over the Tracks field.
- Save the current iteration entry, and iterate over the list again.
- When mainTarget.Name == current.Name, and such, then remove the entry.
The ID's are unique. But the Title name, Album name, and stuff like that, is
not!
And, there are of course files that are simply named "Track {NN}.mp3"... so I
would have to skip these in the iteration, to get the list of "named songs"
cleaned.
My question to you guys is:
- Do you think this is a good aproach?
- Which Plist reader would you recomend?
Kind regards, Ingwie!
--
--
Job Board: http://jobs.nodejs.org/
Posting guidelines:
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en
---
You received this message because you are subscribed to the Google Groups
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.