srid / neuron

Future-proof note-taking and publishing based on Zettelkasten (superseded by Emanote: https://github.com/srid/emanote)
https://neuron.zettel.page
GNU Affero General Public License v3.0
1.52k stars 150 forks source link

Files with `§` in title not recognized #595

Closed danymat closed 3 years ago

danymat commented 3 years ago

I'm currently using the § character to add structure to my ZK (§§, §1, etc). I think this character is not recognized by neuron

Steps to reproduce

  1. Create a file test.md
  2. Create a second file §2\ test.md
  3. Link the second file in the first file
  4. Only the first file will be recognized
srid commented 3 years ago

How are you linking to it?

See also https://github.com/srid/neuron/issues/446

danymat commented 3 years ago

For example I have a file called: 202102241246 §1 Zettelkasten.md

In its content I have:

## Objectif

- [[202102081550 L'objectif d'un slip-box]]

which is linking the file 202102081550 L'objectif d'un slip-box.md

The problem is that even neuron query doesn't return any file with a § on it.

srid commented 3 years ago

Okay. That character is not allowed in the whitelist:

https://github.com/srid/neuron/blob/833ab699e1ec3d8644130e7ac5f1539f118a1552/src/Neuron/Zettelkasten/ID.hs#L81-L99

I'm trying to recall the rationale for that. Filesystem filepath and URI limitations are the main reason I think.

danymat commented 3 years ago

Nice, I was wondering where you defined the parsing whitelist. I propose to add this special character to the whitelist (except if there is a way to add personal whitelist in the config file)

srid commented 3 years ago

Sounds good to me, feel free to open a PR (the CI will catch any errors).