If we’re using git (and it’s been set up properly) the committer email should be there in the commit. Could you grab that instead of the username using a command like
git show -s --pretty=format:"%ae" 4d2df873da3d45831f4eb410b1fc52ab496478b3
Note that git-svn does something a little odd with author emails, so your mileage may vary…looks like there are ways to clone an svn repo while supplying a username->email mapping, so we should experiment with that when we’ve sorted out our user list.
> On Aug 12, 2015, at 12:56 , Martin Holmes <[log in to unmask]> wrote:
> On 15-08-12 09:31 AM, Hugh Cayless wrote:
>> If you know the user’s GitHub handle, and if they’ve provided an email,
>> you can look it up via the GitHub API, e.g.
>> https://api.github.com/users/martindholmes (look for the "email" field),
>> so usually it would be pretty simple to get an email for a committer and
>> email them at that address. I think GitHub made the decision a few years
>> back that they didn’t want to be in the messaging business—that’s what
>> email is for, after all.
> Yes, I've been looking at that, but it's not clear to me how we could build this into the Jenkins build process. What Jenkins does is:
> Did the build fail?
> If so, check the repo for the last committer, and combine that with the default email address suffix and send mail to it.
> We have no control over that, other than providing the suffix, and a fixed list of email addresses to which the email will be copied. We'd have to add a post-build step of some kind -- and I don't see one that fits the bill -- to do the API call, parse the JSON and send the email. I don't think it's trivial to do.
> If we decide it's essential, we could do more investigation.
>> All the best,
>> * Hugh A. Cayless, Ph.D
>> * Chair, TEI Technical Council
>> * Duke Collaboratory for Classics Computing (DC3)
>> * [log in to unmask] <mailto:[log in to unmask]>
>> * http://blogs.library.duke.edu/dcthree/
>>> On Aug 12, 2015, at 11:31 , Martin Holmes <[log in to unmask]
>>> <mailto:[log in to unmask]>> wrote:
>>> The way our Jenkins servers are set up, a single email suffix is set
>>> up globally, which projects can then use; right now, that's set to
>>> @users.sourceforge.net <http://users.sourceforge.net>, and it's used
>>> by the P5 builds (so if I commit a change which breaks the build, an
>>> email will be sent to [my_sf_username]@users.sourceforge.net
>>> <http://users.sourceforge.net>; that auto-forwards to my real email
>>> address because my SF account is set up to do that.
>>> The projects we have that currently build on GitHub can't use this
>>> global setting, so they just email myself and Sebastian directly.
>>> There is a more sophisticated email plugin for Jenkins which we could
>>> install, which would enable per-project email suffixes, but since we
>>> may be moving P5 to GitHub anyway, it probably makes sense to wait and
>>> see how that works out.
>>> I just tried sending myself an email at [myusername]@users.github.com
>>> <http://users.github.com> and to [myusername]@github.com
>>> <http://github.com>, but it appears there's no mail forwarding system
>>> in place for GitHub as there is for SourceForge, so I don't think
>>> we'll be able to maintain the same notification system for builds from
>>> GitHub repos.
>>> On 15-08-12 05:43 AM, Martin Holmes wrote:
>>>> Hi Stuart,
>>>> Jenkins is set up to send an email to a committer only when a build
>>>> fails following their commit; however, that was originally set up with
>>>> SourceForge (meaning that it sends to an email address created by your
>>>> SourceForge committer id, which is all it knows about), and you would
>>>> have to have SF set up to forward on such mail before you'd get it. That
>>>> works for P5 builds.
>>>> However, as James has pointed out, the Stylesheets are now on GitHub,
>>>> and you've reminded me that I haven't really checked into what's
>>>> happening there; I'll take a look and see if a similar process can be
>>>> set up for GitHub commits.
>>>> On 15-08-12 02:26 AM, Stuart A. Yeates wrote:
>>>>> I've got a change I'd like to make to the stylesheets used to generate
>>>>> the HTML version of the standard (a minor change to regularise the
>>>>> display of attribute values), but I'm not quite sure how to go about it.
>>>>> Do I just push a change request to https://github.com/TEIC/Stylesheets ?
>>>>> Or fork it? Does that get tested by jenkins?
>>>>> Jenkins used to send me emails when it ran a job based on my commits,
>>>>> but I've not seen one for a couple of recent commits, is that because
>>>>> I'm not on the council any more?
>>>>> ...let us be heard from red core to black sky