Skip to content
This repository was archived by the owner on Jan 13, 2019. It is now read-only.

Commit 2bf405d

Browse files
authored
Merge pull request #1 from corpsee/feature-readme-fix
Small fixes
2 parents 7741c0c + 8e0d59f commit 2bf405d

File tree

2 files changed

+5
-11
lines changed

2 files changed

+5
-11
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/a58c62e4bde1485f95b52fa56a2e4320)](https://www.codacy.com/app/LEXASOFT/PHP-Censor-Telegram-Plugin)
44
# PHP-Censor-Telegram-Plugin
5-
Telegram plugin for PHP Censor
5+
Telegram plugin for [PHP Censor](https://github.com/corpsee/php-censor)
66
# Installation
77
First of all - `composer require lexasoft/php-censor-telegram-plugin`
88

@@ -12,7 +12,7 @@ In the PHP Censor Project config section add the Telegram trigger
1212
complete:
1313
telegram:
1414
api_key: "<YOUR_BOT_TOKEN_HERE>"
15-
message: [%ICON_BUILD%] [%PROJECT_TITLE%](%PROJECT_URI%) - [Build #%BUILD%](%BUILD_URI%) has finished for commit [%SHORT_COMMIT% (%COMMIT_EMAIL%)](%COMMIT_URI%) on branch [%BRANCH%](%BRANCH_URI%)
15+
message: "[%ICON_BUILD%] [%PROJECT_TITLE%](%PROJECT_URI%) - [Build #%BUILD%](%BUILD_URI%) has finished for commit [%SHORT_COMMIT% (%COMMIT_EMAIL%)](%COMMIT_URI%) on branch [%BRANCH%](%BRANCH_URI%)"
1616
recipients:
1717
- <user id>
1818
- "-<group id>"

src/Telegram.php

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,4 @@
11
<?php
2-
/**
3-
* PHPCI - Continuous Integration for PHP
4-
*
5-
* @copyright Copyright 2014, Block 8 Limited.
6-
* @license https://github.com/Block8/PHPCI/blob/master/LICENSE.md
7-
* @link https://www.phptesting.org/
8-
*/
92

103
namespace PHPCensor\Plugin;
114

@@ -15,6 +8,7 @@
158

169
/**
1710
* Telegram Plugin
11+
*
1812
* @author LEXASOFT <lexasoft83@gmail.com>
1913
* @package PHPCensor
2014
* @subpackage Plugins
@@ -121,9 +115,9 @@ private function buildMessage()
121115
$buildIcon = $this->build->isSuccessful() ? '' : '';
122116
$buildLog = $this->build->getLog();
123117
$buildLog = str_replace(['[0;32m', '[0;31m', '[0m', '/[0m'], '', $buildLog);
124-
$buildmessages = explode('RUNNING PLUGIN: ', $buildLog);
118+
$buildMessages = explode('RUNNING PLUGIN: ', $buildLog);
125119

126-
foreach ($buildmessages as $bm) {
120+
foreach ($buildMessages as $bm) {
127121
$pos = mb_strpos($bm, "\n");
128122
$firstRow = mb_substr($bm, 0, $pos);
129123

0 commit comments

Comments
 (0)