-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refusing to process one example in docs #12
Comments
OK I located the bug - there seems to be some issue if the regex files are created with windows notepad and/or the index./txt file is edited with windows notepad. If that is done then the newly created rules are "found" but do not work (even though the files look ostensibly identical and obsidian is restarted). Perhaps something to do with line break format in these files? Creating the identical rule within the inbuilt editor works fine prefix a2 -- works fine The latter was created with windows inbuilt notepad.exe and says it is Windows-1252 |
I opened the files with VSCode and it shows UTF8, UTF16LE, which seems match the result only the first works. |
Yes. I think it probably needs a line in the documentation to point this out - because the error report does not immediately lead one to the problem and it took a long time to figure this out. Probably would also be good when the thing flashes up to say what processing has been done, if the number of regexes in the file is zero, it might hint as to a possible cause (is file in UTF-8 format). Especially because the nature of the plugin is that an external editor is likely to be used. |
As this does not seem common for now, I'll mention this only in the Readme. Thanks for testing this out! |
This is a fantastic plugin - thank you so much for writing it
I have one curious anomaly
All my own regexes work fine, and all the other examples work fine, but one example in the docs throws up an error. It is this one.
Whatever I do it says "which contains 0 regex replacements" and does nothing at all. I wondered whether one of the characters might be a unicode character that is not what it seems, so retyped it from scratch, but no matter what I do this attempt to pre-pend something to lines (from the docs) does not work
"^(.+)$"->">$1"
The text was updated successfully, but these errors were encountered: