quebin31 / muso

muso: music sorter
GNU General Public License v3.0
90 stars 5 forks source link

Add options to make tags optional #8

Closed n0emis closed 4 years ago

n0emis commented 4 years ago

When a file has e.g. have a value for the Disc-Tag and I wan't to include this in the sorting. (for example with the followinf format-string: {artist}/{album}/{disc}{track} - {title}.{ext}). When there are now files without that tag, these files will not get sorted.

Therefor I propose a feature: some kind of optional-marker which can be added to tags.

quebin31 commented 4 years ago

The first option that comes to my mind is something like this: {disc?}. This may be straightforward but I see one restriction "optional tags" may not be used for non-file components in the format string.

Valid: {artist}/{disc?} - {title}.{ext} Invalid: {artist?}/{disc?} - {title}.{ext}

Also {ext} cannot be optional and the file component must have at least one non-optional tag (e.g. title, track, etc.)