Add sanity checks to template filenames for unsupported characters

Hi,

I tried to change the Zettelkasten note filename to include either a colon : or a pipe | or a combination of both. If either of these glyphs is in the filename for a new Zettelkasten note, the creation of a note silently fails and no error is given.

I’m on linux and colons and pipe symbols are valid in filenames, but this may be different on Windows, so I don’t know if it’s a file system limitation. If not, it would be nice to allow them in note file names.

If this is not possible, the settings should disallow forbidden glyphs, preferably with an error message.

1 Like

We don’t support : and | in filenames. We need to add sanity checks to settings

2 Likes

There’s already an auto-complete for Zettelkasten template file, so you shouldn’t manually enter it. The template file has to be an .md file in the vault to work, so I imagine people will use the dropdown to select a template file.

Did I not understand your issue correctly?

@Silver is not for the template file. It’s for the zettel ID format (that becomes a filename itself).

I see, makes a lot more sense then. Thanks for the clarification. When I saw “template” I automatically interpreted that as the template file.

@WhiteNoise is correct, I stated that unfortunate. While I use a template file for the Zettelkasten note, the actual problem is the file name of the newly created file and not related to the template.

I have the Zettenkastel prefixer plugin installed and I tried creating a note. When I click the plugin picture in the leftside “plugin menu” nothing happens. I have created a template and I could choose the note folder and the template in the options. I can also use the template to populate a note through the template plugin. Just I can’t seem to create a new note, which I thought was the idea of the plugin (otherwise you can just use the template plugin).

What am I missing?

post a screenshot of zettelkasten plugin config screen

: is not a valid character for the filename (zettel id format)

Ah, thanks! I changed it and now it works!

: is not a valid character for the filename (zettel id format)

And that’s exactly the problem.

  1. Writing “:” is valid at the disk system level at least in Linux.
  2. Using it also works properly in a preview.
  3. No error is being displayed. “Create new zettel note” button is being clicked, but nothing happens.

I encountered the same issue now and it took me quite some time to figure out why it doesn’t work. And I am an IT professional…

So either characters like “:” should become valid or it should show an error both in the preview as well as trying to invoke (button or hotkey) the “create new zettel note” functionality.

1 Like