| [reply] |
And if the track number is more than 2 digits?
Update: Oops! It seems that I didn't read the challenge carefully.
buzzcutbudda specified that the track number would only be two digits.
Thanks for the heads up, nothingmuch.
| [reply] |
I think I would go for ()=/\d+-(.*)/g
-nuffin zz zZ Z Z #!perl
| [reply] [d/l] |
The id3v1 spec only has space for a two-digit track number. (IIRC, theoreticaly, you could put any two characters in, so you could count in hex, base-36, or whatever if you need more space, up to a theoretical max of 254**2, with any two chars, other then \0, which probably has special meaning. I don't remember id3 that well off the top of my head.)
Warning: Unless otherwise stated, code is untested. Do not use without understanding. Code is posted in the hopes it is useful, but without warranty. All copyrights are relinquished into the public domain unless otherwise stated. I am not an angel. I am capable of error, and err on a fairly regular basis. If I made a mistake, please let me know (such as by replying to this node).
| [reply] |
I believe it's the case that the CD spec itself limits a disc to 99 tracks anyway.
| [reply] |