I know removing trailing whitespace can be done with a pre-commit hook. I am interested in doing it manually. I read the question here: Make git automatically remove tra
If you use emacs, you can use "M^x delete-trailing-whitespace" to delete them before saving the file. (it can be customized in your .emacs also)
vi seems to also allow this : http://vim.wikia.com/wiki/Remove_unwanted_spaces