Open orbea opened 8 years ago
This is by design, and not going to be changed. Changing this to be sorted by metadata would break far more use cases, than fix.
Out of curiosity do you have an example of a use case this would break? Even if this behavior is not added there are less drastic ways of "solving" this. Like if it were possible to sort only highlighted tracks in a playlist than the entire playlist.
Would it still break use cases if this was an optional feature so that users could choose how they want tracks sorted by default? Bluntly, this is a major issue as far as my personal use case is concerned. :)
Out of curiosity do you have an example of a use case this would break?
Yeah.. how would you sort this? I couldn't make the sorting work. There are many other corner cases like this, which work fine when sorting by %path%, but would require special code if you want to sort by metadata.
edit: I needed to mention that my Track Nr. title formatting is this %tracknumber%[ \[disc %disc%[/%numdiscs%]\]]
, but the main point is that there are 2 CDs with tracks in each of them starting from 00, with identical album/artist.
edit2: Another obvious corner case is when some files don't have any metadata. That would especially be a problem when adding a large collection to the same playlist recursively. Many albums would get messed up.
Like if it were possible to sort only highlighted tracks in a playlist than the entire playlist.
This issue is asking to sort the files by metadata, when they're being added to playlist. If you want to request another feature -- e.g. sorting selected tracks -- please post a new feature request.
Would it still break use cases if this was an optional feature so that users could choose how they want tracks sorted by default?
I closed this because of the way this issue is written - as a bug. It implies changing the way files are sorted from their natural (fs-based) sorting to post-process sorting, based on metadata. This is not going to happen.
Rewording this issue into a feature request to add an option to automatically sort the added files after adding them to playlist -- would work better.
@orbea
I'm open to suggestions which title formatting to use for default post-process sorting.
I'd start with something like this:
$directory_path(%path%)
[%disc%]
%track number%
%album%
%artist%
another script idea
$directory_path(%path%)-
$if2($pad(%disc%,2,0),00)-
$if2(%track number%,00)-
[%album%]-
[%artist%]
This might even work.
($pad is not implemented yet though, but that's not a big deal to add)
I was not sure on how you thought would be the best way to address this so I left my wording possibly vague.
The problem with my use case is that my music library is extensive and the CDs I ripped years ago don't have the track number in the file name. So this left my music directory with inconsistent naming conventions which would take a lot of work to untangle. This has never been a problem with other players (cmus, fb2k) because they relied exclusively on the metadata defaulting to the file name only if the metadata was missing.
With deadbeef it adds tracks with only the file name, so that it fails with a huge portion of my music library leaving me to sort albums manually by hand. This is a minor and constant inconvenience except for the few albums with 20+ tracks where it becomes more work to sort than reasonable.
My ideal solution would be to add two features.
I did not think of the script idea when I made this issue report, I'm not really sure how effectively it would solve my personal use case yet. Though I am certainly open to trying it. :)
I did not think of the script idea
That's the only way how sorting works in deadbeef - it's always a title formatting script.
OS:
Slackware64-current
deadbeef-8214e4f_2016.04.22_master-x86_64-1_git
When adding folders (albums) to a playlist the tracks are added in the order of the file names rather than being sorted by the track number included in the metadata as in music players such as cmus or fb2k.
In the below example the albums
Monotony Fields
andShades Of
are added in the correct order whileIllusion's Play
andangels of distress
are added in the incorrect track order. This is especially annoying as the sort option is not capable of sorting only the highlighted tracks as in fb2k and requires the albums to be sorted by hand each time they are added to a playlist.