Changeset View
Changeset View
Standalone View
Standalone View
src/repository/marker/ArcanistGitRepositoryMarkerQuery.php
Show First 20 Lines • Show All 66 Lines • ▼ Show 20 Lines | foreach ($lines as $line) { | ||||
$remote_name = $parts[0]; | $remote_name = $parts[0]; | ||||
$name = $parts[1]; | $name = $parts[1]; | ||||
} else { | } else { | ||||
// For now, discard other refs. | // For now, discard other refs. | ||||
continue; | continue; | ||||
} | } | ||||
$marker = id(new ArcanistMarkerRef()) | $marker = (new ArcanistMarkerRef()) | ||||
->setName($name) | ->setName($name) | ||||
->setMarkerType($type) | ->setMarkerType($type) | ||||
->setEpoch((int)$epoch) | ->setEpoch((int)$epoch) | ||||
->setMarkerHash($hash) | ->setMarkerHash($hash) | ||||
->setTreeHash($tree) | ->setTreeHash($tree) | ||||
->setSummary($summary) | ->setSummary($summary) | ||||
->setMessage($text); | ->setMessage($text); | ||||
▲ Show 20 Lines • Show All 86 Lines • ▼ Show 20 Lines | foreach ($lines as $line) { | ||||
if (!strncmp($ref, $branch_prefix, $branch_length)) { | if (!strncmp($ref, $branch_prefix, $branch_length)) { | ||||
$type = ArcanistMarkerRef::TYPE_BRANCH; | $type = ArcanistMarkerRef::TYPE_BRANCH; | ||||
$name = substr($ref, $branch_length); | $name = substr($ref, $branch_length); | ||||
} else { | } else { | ||||
// For now, discard other refs. | // For now, discard other refs. | ||||
continue; | continue; | ||||
} | } | ||||
$marker = id(new ArcanistMarkerRef()) | $marker = (new ArcanistMarkerRef()) | ||||
->setName($name) | ->setName($name) | ||||
->setMarkerType($type) | ->setMarkerType($type) | ||||
->setMarkerHash($hash) | ->setMarkerHash($hash) | ||||
->setCommitHash($hash); | ->setCommitHash($hash); | ||||
$commit_ref = $api->newCommitRef() | $commit_ref = $api->newCommitRef() | ||||
->setCommitHash($hash); | ->setCommitHash($hash); | ||||
Show All 9 Lines |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0