Fix #918: trim whitespace around commit message