Emacs: replace tabs with spaces
Posted on Tue 04 April 2017 in blog
When you want to replace tab with spaces or vice versa don't use M-%
(query-replace) but M-x tabify
or M-x untabify
. They work on the
current selection so if you want it to be applied to a whole buffer,
try C-x h
(mark-whole-buffer) before to select the whole buffer.