Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Properly sort track number #7

Open
erodozer opened this issue Feb 14, 2017 · 2 comments
Open

Properly sort track number #7

erodozer opened this issue Feb 14, 2017 · 2 comments

Comments

@erodozer
Copy link
Collaborator

Attempt to parse a track number into an int and sort numerically when possible.

example

@erodozer
Copy link
Collaborator Author

Found another case that we need to fix sorting by

screen shot 2017-04-13 at 1 27 37 pm

@erodozer
Copy link
Collaborator Author

looks like a simple solution is just finding the number of digits of the largest number in the list and expanding the int to that length. This might not work well for large directories or recursing.

For the types of tracks with the number divided by a /, we can simply parse the whole halves and make sure the lengths match with padding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant