Closed dapc11 closed 1 year ago
Sorry, should have included that into the commit message. It was basically a note that I created outside the Zettelkasten workflow, thus forgot adding a proper header to the top of the document.
But the note's file name matches the pattern, right? If that's the case, the id of the note is actually the file name without the extension. And If we can't find the expected format for the title, maybe we can use the first non-empty line as the note title.
What do you think about that?
Yes it did, it was just that the title part (not date) of the heading that was missing.
Yes it did, it was just that the title part (not date) of the heading that was missing.
In that case I think the node ID should be extracted from the file name, and we should use the first non empty line as the title (Excluding the note id part if it's still there). Returning nil
and not showing that note doesn't sound right to me.
Would you be willing to make that change?
In my pull request for #19 (#21) I implemented explicit flags that allow you to specify whether to use the title or the filename (or both) for determining the id. It rases an error if you use both and they don't match. It does not do what this pull request does and raise an error if it could not extract it from the title.
I think #21 is an appropriate solution to this problem as well. Thank you for the contribution! If the new solution doesn't work for you, we can revisit this idea.
Hey! Thanks for the PR.
Can you describe what a faulty note is?