SebastianMC / obsidian-custom-sort

Take full control over the order and sorting of folders and notes in File Explorer in Obsidian
GNU General Public License v3.0
252 stars 19 forks source link

Asses the complexity of adding support for two levels (or multi-level) sorting #86

Closed SebastianMC closed 10 months ago

SebastianMC commented 10 months ago

The issue #85 requires the two levels sorting. Investigate the complexity of adding such capability.

What syntax? Using indentation (nesting) seems tempting:

  // indentation-based multi-level sorting syntax (potential)
  target-folder: Journal
  > a-z by-metadata: date
    < a-z by-metadata: time

yet this is already used to distinguish between folder-level sorting and group-level sorting. Road closed in this direction. Also, indentation turned out to be troublesome for copy & paste of sorting spec from a web page (e.g. documentation on github) or from email. Another reason to avoid this direction.

The other (and safer) option is to involve the comma-separated list of sorting levels:

  // comma-separated notation for multi-level sorting
  target-folder: Journal
  > a-z by-metadata: date, < a-z by-metadata: time

Before implementing this capability assess the complexity, if it is not an overkill

Take into account the existing cumbersome syntax for multi-level alike sorting:

  < a-z, created

If implementing the straight explicit multi-level sorting seems to be too complex (to be worth it), some simpler options do exist, more specific, less generic:

SebastianMC commented 10 months ago

The assessment is done, implementation of multi-level (2-3) sorting is feasible without any significant increase in complexity, will be done under #89: