Added automatic removal of trailing whitespace