feat: Add repo mirror-sync endpoint

This commit is contained in:
Michael Gerdemann
2020-01-19 11:05:11 +01:00
parent e9636cc070
commit bfb83eb719

View File

@ -236,4 +236,16 @@ trait RepositoryTrait
$response = $this->client->request(self::BASE_URI . '/' . $owner . '/' . $repositoryName, 'PATCH', $options); $response = $this->client->request(self::BASE_URI . '/' . $owner . '/' . $repositoryName, 'PATCH', $options);
return \GuzzleHttp\json_decode($response->getBody(), true); return \GuzzleHttp\json_decode($response->getBody(), true);
} }
/**
* @param string $owner
* @param string $repositoryName
* @return bool
*/
public function mirrorSync(string $owner, string $repositoryName): bool
{
$this->client->request(self::BASE_URI . '/' . $owner . '/' . $repositoryName . '/mirror-sync', 'POST');
return true;
}
} }