Also adds doom|disable-delete-trailing-whitespace hook, which can be used to disable this behavior on a per-buffer basis. If you want to turn off this global behavior: (remove-hook 'write-file-functions #'delete-trailing-whitespace)