]> khamidou — GitHub mirrors - arcanist.git/commitdiff
Fix commit message format returned by getCommitMessage
authorBrandon Pedersen <BPedersen@novell.com>
Thu, 6 Sep 2012 14:56:44 +0000 (08:56 -0600)
committerBrandon Pedersen <BPedersen@novell.com>
Thu, 6 Sep 2012 14:56:44 +0000 (08:56 -0600)
Git commit messages must have 2 newlines between the subject and body
If used to rewrite a commit message then the commit message will be
incorrectly reformatted.

src/repository/api/ArcanistGitAPI.php

index 2945525e5f07d863d5c5efe153ef82082652d3e4..e92244b908242dc1d4ff0242dfabf9afd8d4c25d 100644 (file)
@@ -753,7 +753,7 @@ final class ArcanistGitAPI extends ArcanistRepositoryAPI {
   public function getCommitMessage($commit) {
     list($message) = $this->execxLocal(
       'log -n1 --format=%C %s --',
-      '%s%n%b',
+      '%s%n%n%b',
       $commit);
     return $message;
   }