Merge pull request #150 from c2is/master
Added GitLab infos (WebHook url) in the project page if it's a GitLab's project
This commit is contained in:
commit
b7bf0fed51
|
@ -18,7 +18,7 @@
|
|||
<?php endif; ?>
|
||||
</ul>
|
||||
|
||||
<?php if (in_array($project->getType(), array('github', 'bitbucket'))): ?>
|
||||
<?php if (in_array($project->getType(), array('github', 'gitlab','bitbucket'))): ?>
|
||||
<br>
|
||||
<p class="alert alert-info">To automatically build this project when new commits are pushed, add the URL below
|
||||
<?php endif; ?>
|
||||
|
@ -31,6 +31,11 @@
|
|||
print ' as a "WebHook URL" in the <a href="https://github.com/' . $project->getReference() . '/settings/hooks">Service Hooks</a> section of your Github repository.<br><br><strong style="word-wrap: break-word;">' . $url . '</strong>';
|
||||
break;
|
||||
|
||||
case 'gitlab':
|
||||
$url = (empty($_SERVER['HTTPS']) ? 'http' : 'https') . '://' . $_SERVER['HTTP_HOST'] . '/gitlab/webhook/' . $project->getId();
|
||||
print ' as a "WebHook URL" in the Web Hooks section of your Gitlab repository.<br><br><strong style="word-wrap: break-word;">' . $url . '</strong>';
|
||||
break;
|
||||
|
||||
case 'bitbucket':
|
||||
$url = (empty($_SERVER['HTTPS']) ? 'http' : 'https') . '://' . $_SERVER['HTTP_HOST'] . '/bitbucket/webhook/' . $project->getId();
|
||||
print ' as a "POST" service in the <a href="https://bitbucket.org/' . $project->getReference() . '/admin/services">Services</a> section of your Bitbucket repository.<br><br><strong style="word-wrap: break-word;">' . $url . '</strong>';
|
||||
|
|
Loading…
Reference in a new issue