X-Git-Url: https://git.cweiske.de/phorkie.git/blobdiff_plain/2935763e253c3616d951bc18c7d21a56349531fa..5d065586f4c16c0ec6510dba97b0d5facb859d75:/src/phorkie/Repository.php diff --git a/src/phorkie/Repository.php b/src/phorkie/Repository.php index 9f8f264..25b049c 100644 --- a/src/phorkie/Repository.php +++ b/src/phorkie/Repository.php @@ -104,6 +104,11 @@ class Repository $this->hash = $output; } + /** + * Populates $this->message + * + * @return void + */ public function loadMessage() { $rev = (isset($this->hash)) ? $this->hash : 'HEAD'; @@ -252,6 +257,8 @@ class Repository return '/' . $this->id; } else if ($type == 'fork') { return '/' . $this->id . '/fork'; + } else if ($type == 'doap') { + return '/' . $this->id . '/doap'; } else if ($type == 'delete') { return '/' . $this->id . '/delete'; } else if ($type == 'delete-confirm') { @@ -303,6 +310,13 @@ class Repository $commit->committerName = $arOutput[$current + 2]; $commit->committerEmail = $arOutput[$current + 3]; + if (substr($arOutput[$current + 4], 0, 1) != ' ') { + //commit without changed lines + $arCommits[] = $commit; + $current += 4; + continue; + } + $arLineParts = explode(' ', trim($arOutput[$current + 4])); $commit->filesChanged = $arLineParts[0]; $commit->linesAdded = $arLineParts[3];