Skip to content

How to apply different sortspec to folders and notes? #100

Discussion options

You must be logged in to vote

Hi @pinetreemoonlight,

if I get your question correctly, you need the below sorting specification:

---
sorting-spec: |
  target-folder: /
  /folders ...
    < a-z
  /:files ...
    > created
---

You read it as:

  • inside the root folder of the vault (this is specified as target-folder: /)
  • collect all subfolders in the top (/folders ...)
  • and order them alphabetically (the indented < a-z order specification)
  • then go all files (/:files ...)
  • ordered by creation date, newer first (the indented > created)

Indentation matters - the two order specifications have to be indented at least one space more than the surrounding lines

At the same time: do I get your question correctly? Because the exact…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by SebastianMC
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #99 on October 05, 2023 20:22.