From 2f4063c7885db9760afe1697d75cb72258b29b78 Mon Sep 17 00:00:00 2001 From: Jimmy Cleuren Date: Sat, 18 Oct 2014 16:52:07 +0200 Subject: [PATCH] Add a commit message to builds imported via PollCommand. Closes #626 --- PHPCI/Command/PollCommand.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/PHPCI/Command/PollCommand.php b/PHPCI/Command/PollCommand.php index 61fe0909..f108a35b 100644 --- a/PHPCI/Command/PollCommand.php +++ b/PHPCI/Command/PollCommand.php @@ -75,6 +75,7 @@ class PollCommand extends Command $last_commit = $commits['body'][0]['sha']; $last_committer = $commits['body'][0]['commit']['committer']['email']; + $message = $commits['body'][0]['commit']['message']; $this->logger->info("Last commit to github for " . $project->getTitle() . " is " . $last_commit); @@ -89,6 +90,7 @@ class PollCommand extends Command $build->setStatus(Build::STATUS_NEW); $build->setBranch($project->getBranch()); $build->setCreated(new \DateTime()); + $build->setCommitMessage($message); if (!empty($last_committer)) { $build->setCommitterEmail($last_committer); }