Suppose I have
bár written in a file, I would like to look for
swiper and find the occurrences of
bár alongside the expected occurrences of
bar, how I can do this? This would also apply to characters like e=é=è, o=ö, u=ü, a=å, o=ó=ö, c=ç, etc.
bár is called character folding, and is supported by the built-in functions
query-replace since Emacs 25; see
(emacs) Lax Search and
(emacs) Search Customizations for details.
swiper automatically performs character folding when
search-default-mode is set to the function
char-fold-to-regexp, which you can achieve by e.g. adding
(setq search-default-mode #'char-fold-to-regexp)