Allow some folders to be ignored

It would be helpful to have an option of having a list of folders to ignore in Notenik collections with a folder field (sort of like .gitignore). This will be useful when one generates output markdown files in sub-folders using templates, but don’t want to see these in the collection notes and also to ignore templates and some other files that other PKM apps tend to create.

Is there some file type (based on extension and/or name) that could be used to identify folders best ignored?

For my current uses, “.tempates” (possibly any folder starting with “.”) which is used to store templates by another app (Octarine) and “Daily” which is used to store Daily notes by the same app (though in some collections, it might be useful to see the Daily notes in Notenik). To deal with future additions to the list of such folders, it would be useful for the user to be able to edit this list on a per collection basis or in settings for all collections.
I noticed that Notenik already ignores folders like class, share and reports, so I can store outputs generated through Notenik’s share button in one of these folders if I don’t want it to appear in the collection.

What about storing a list of such folders in a .nnkignore file placed within the top level collection?

1 Like

That would work well!

OK. Let me try something along those lines.

Try the latest beta and let me know how this works for you.

I ended up just allowing a list of folders to be excluded to be specified on the field’s line in the collection template file. For example:

Folder: <folder: excluding: sub 2, sub 3, >

A template line like this would exclude folders named sub 2 or sub 3.

Also, any sub-folders whose names begin with a dot should be automatically excluded.

Works well so far in my testing. Thank you!

1 Like