Strip trailing whitespace.
Add trailing slash to directories in .gitignore.

Having the trailing slash makes git-clean operations with directories
and ignored files work correctly.
Merge pull request #29 from nuclearsandwich/template-cleanup

Template cleanup
Merge remote-tracking branch 'upstream/master'