1

To replace

```
code blocks fenced with backticks
```

with

~~~
code blocks fenced with tildas
~~~

I can use :%s/```/\~\~\~/g and this works.

However, when I try to replace them with GUI (Edit > Find and Replace), neither \~\~\~, nor ~~~ in the "Replace with" field works for me.

What is wrong here?

1 Answer 1

4

This is a bug. Tilde and ampersand are special for :h sub-replace and "ReplaceAll" handler in src/gui.c:gui_do_findrepl() does incorrect escaping.

I've raised the issue.

Upd. Fixed in 9.0.0396.

1
  • Dang. Mine is 9.0.0389. If I'd only waited a few days. :)
    – MDeBusk
    Commented Sep 7, 2022 at 14:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.