Better format for email hook (BB-9388)
The 2 options for Commit emails aren't very useful. For example, if I'd like to notify a fellow coder of a change I made, I certainly would never send them this:
1 new commit in MagicRepo:
https://bitbucket.org/b9chris/magicrepo/commits/b360b69bbac6/ Changeset: b360b69bbac6 Branch: SupportUsChanges User: bramlage Date: 2013-10-05 05:52:03 Summary: Updated SupportUs/Index.cshtml Store, still waiting on full product views and paypal buttons for two new shirts
Affected #: 6 files
Repository URL: https://bitbucket.org/b9chris/magicrepo/
This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.
That's a ton of chaff for the one thing that's actually useful about that email:
Updated SupportUs/Index.cshtml Store, still waiting on full product views and paypal buttons for two new shirts
Except often the actual commit message I want to see is clipped.
I assume some users are using this bad-for-humans email in systems automation, so would it be possible to add a third more usable email option? Happy to work with you on the format. Here's an initial proposal:
MagicRepo - 3 commits - b9chris - 2013-10-30
(Date prevents Gmail from threading update emails infinitely)
(no summary of how many commits - that's clear from the list of commits we're about to iterate)
2013-10-05 05:52:03 Updated SupportUs/Index.cshtml Store, still waiting on full product views and paypal buttons for two new shirts
Update me when stills available.
SupportUs/Index.cshtml +6, -3, *7
So, you get the full commit message, instead of presuming that just the first line is all that's important. Most of the irrelevant stuff like a link to commit, the commit hash, etc is left out - all fine things to have but they can be found just fine on their own and aren't relevant to a quick summary. Then a summary of changed files with number of lines added, removed, changed. Branch is at the end since it's rarely a value you don't already anticipate (whatever your workflow), but occasionally relevant.