etc: indent-code.el: Remove any existing tabs.

* etc/indent-code.el (main): Call UNTABIFY on the sexp or entire buffer.
This commit is contained in:
Tobias Geerinckx-Rice 2021-06-02 14:26:28 +02:00
parent f5d9d6ec68
commit 0b17dc4aae
No known key found for this signature in database
GPG key ID: 0DB0FF884F556D79

View file

@ -99,6 +99,8 @@
nil t)
(let ((indent-tabs-mode nil))
(beginning-of-defun)
(mark-sexp)
(untabify (point) (mark))
(indent-sexp)
(save-buffer)
(message "Done!"))
@ -108,6 +110,7 @@
;; Indent all of FILE-NAME.
(find-file file-name)
(let ((indent-tabs-mode nil))
(untabify (point-min) (point-max))
(indent-region (point-min) (point-max))
(save-buffer)
(message "Done!")))