fiatjaf / neuron.vim

📝 Manage your Zettelkasten in {n}vim.
MIT License
83 stars 21 forks source link

Fix autocmd filename escape on Linux #35

Closed pauljxtan closed 3 years ago

pauljxtan commented 3 years ago

Previously, the fnameescape() causes the wildcard asterisk to be escaped in the pattern - resulting in e.g. /my/neuron/dir/\*.md - which unfortunately doesn't set the autocommands correctly on my system (Linux/Neovim). (Not sure if this applies to Vim or other OSes.)

This PR prevents the wildcard from being escaped.

fiatjaf commented 3 years ago

I didn't understand the reasons or what this does, but it seems to work fine for me. Thank you!

pauljxtan commented 3 years ago

Ah, I didn't explain it that well on second reading, but this just changes the autocmd patterns from /some/dir/\*.md (doesn't work on Linux) to /some/dir/*.md (does work on Linux) :slightly_smiling_face: