Completed
Branch 0.8-dev (01721d)
by Kacper
02:43
created
Utils/Console.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- *
7
- * @author Kacper "Kadet" Donat <[email protected]>
8
- *
9
- * Contact with author:
10
- * Xmpp: [email protected]
11
- * E-mail: [email protected]
12
- *
13
- * From Kadet with love.
14
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     *
7
+     * @author Kacper "Kadet" Donat <[email protected]>
8
+     *
9
+     * Contact with author:
10
+     * Xmpp: [email protected]
11
+     * E-mail: [email protected]
12
+     *
13
+     * From Kadet with love.
14
+     */
15 15
 
16 16
 namespace Kadet\Highlighter\Language;
17 17
 
Please login to merge, or discard this patch.
Utils/ConsoleHelper.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- *
7
- * @author Kacper "Kadet" Donat <[email protected]>
8
- *
9
- * Contact with author:
10
- * Xmpp: [email protected]
11
- * E-mail: [email protected]
12
- *
13
- * From Kadet with love.
14
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     *
7
+     * @author Kacper "Kadet" Donat <[email protected]>
8
+     *
9
+     * Contact with author:
10
+     * Xmpp: [email protected]
11
+     * E-mail: [email protected]
12
+     *
13
+     * From Kadet with love.
14
+     */
15 15
 
16 16
 namespace Kadet\Highlighter\Language;
17 17
 
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
 
33 33
     public function styled($style, $text)
34 34
     {
35
-        return $this->open($style).$text.$this->close();
35
+        return $this->open($style) . $text . $this->close();
36 36
     }
37 37
 
38 38
     public function open($style)
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
     {
52 52
         $this->_current = empty($this->_stack) ? $this->_default : array_pop($this->_stack);
53 53
 
54
-        return "\033[0m".$this->_set(array_diff_assoc($this->_current, $this->_default));
54
+        return "\033[0m" . $this->_set(array_diff_assoc($this->_current, $this->_default));
55 55
     }
56 56
 
57 57
     private function _color($name, $bg = false)
@@ -103,9 +103,9 @@  discard block
 block discarded – undo
103 103
 
104 104
     private function _set($style)
105 105
     {
106
-        $escape = "\e[".implode(';', array_map(function ($style, $name) {
106
+        $escape = "\e[" . implode(';', array_map(function($style, $name) {
107 107
             return $this->_style($style, $name);
108
-        }, array_keys($style), $style)).'m';
108
+        }, array_keys($style), $style)) . 'm';
109 109
 
110 110
         return $escape === "\e[m" ? null : $escape;
111 111
     }
Please login to merge, or discard this patch.
Utils/StringHelper.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- *
7
- * @author Kacper "Kadet" Donat <[email protected]>
8
- *
9
- * Contact with author:
10
- * Xmpp: [email protected]
11
- * E-mail: [email protected]
12
- *
13
- * From Kadet with love.
14
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     *
7
+     * @author Kacper "Kadet" Donat <[email protected]>
8
+     *
9
+     * Contact with author:
10
+     * Xmpp: [email protected]
11
+     * E-mail: [email protected]
12
+     *
13
+     * From Kadet with love.
14
+     */
15 15
 
16 16
 namespace Kadet\Highlighter\Language;
17 17
 
Please login to merge, or discard this patch.
Language/PlainText.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- *
7
- * @author Kacper "Kadet" Donat <[email protected]>
8
- *
9
- * Contact with author:
10
- * Xmpp: [email protected]
11
- * E-mail: [email protected]
12
- *
13
- * From Kadet with love.
14
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     *
7
+     * @author Kacper "Kadet" Donat <[email protected]>
8
+     *
9
+     * Contact with author:
10
+     * Xmpp: [email protected]
11
+     * E-mail: [email protected]
12
+     *
13
+     * From Kadet with love.
14
+     */
15 15
 
16 16
 namespace Kadet\Highlighter\Language;
17 17
 
Please login to merge, or discard this patch.
Language/Ini.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- *
7
- * @author Kacper "Kadet" Donat <[email protected]>
8
- *
9
- * Contact with author:
10
- * Xmpp: [email protected]
11
- * E-mail: [email protected]
12
- *
13
- * From Kadet with love.
14
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     *
7
+     * @author Kacper "Kadet" Donat <[email protected]>
8
+     *
9
+     * Contact with author:
10
+     * Xmpp: [email protected]
11
+     * E-mail: [email protected]
12
+     *
13
+     * From Kadet with love.
14
+     */
15 15
 
16 16
 namespace Kadet\Highlighter\Language;
17 17
 
Please login to merge, or discard this patch.
Language/Xml.php 1 patch
Indentation   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -1,16 +1,16 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *1
5
- * Copyright (C) 2016, Some right reserved.
6
- * @author Kacper "Kadet" Donat <[email protected]>
7
- *
8
- * Contact with author:
9
- * Xmpp: [email protected]
10
- * E-mail: [email protected]
11
- *
12
- * From Kadet with love.
13
- */
3
+     * Highlighter
4
+     *1
5
+     * Copyright (C) 2016, Some right reserved.
6
+     * @author Kacper "Kadet" Donat <[email protected]>
7
+     *
8
+     * Contact with author:
9
+     * Xmpp: [email protected]
10
+     * E-mail: [email protected]
11
+     *
12
+     * From Kadet with love.
13
+     */
14 14
 
15 15
 namespace Kadet\Highlighter\Language;
16 16
 
Please login to merge, or discard this patch.
Language/PowerShell.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- *
7
- * @author Kacper "Kadet" Donat <[email protected]>
8
- *
9
- * Contact with author:
10
- * Xmpp: [email protected]
11
- * E-mail: [email protected]
12
- *
13
- * From Kadet with love.
14
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     *
7
+     * @author Kacper "Kadet" Donat <[email protected]>
8
+     *
9
+     * Contact with author:
10
+     * Xmpp: [email protected]
11
+     * E-mail: [email protected]
12
+     *
13
+     * From Kadet with love.
14
+     */
15 15
 
16 16
 namespace Kadet\Highlighter\Language;
17 17
 
Please login to merge, or discard this patch.
Language/JavaScript.php 1 patch
Indentation   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -1,16 +1,16 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- * @author Kacper "Kadet" Donat <[email protected]>
7
- *
8
- * Contact with author:
9
- * Xmpp: [email protected]
10
- * E-mail: [email protected]
11
- *
12
- * From Kadet with love.
13
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     * @author Kacper "Kadet" Donat <[email protected]>
7
+     *
8
+     * Contact with author:
9
+     * Xmpp: [email protected]
10
+     * E-mail: [email protected]
11
+     *
12
+     * From Kadet with love.
13
+     */
14 14
 
15 15
 namespace Kadet\Highlighter\Language;
16 16
 
Please login to merge, or discard this patch.
Matcher/CommentMatcher.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Highlighter
4
- *
5
- * Copyright (C) 2016, Some right reserved.
6
- *
7
- * @author Kacper "Kadet" Donat <[email protected]>
8
- *
9
- * Contact with author:
10
- * Xmpp: [email protected]
11
- * E-mail: [email protected]
12
- *
13
- * From Kadet with love.
14
- */
3
+     * Highlighter
4
+     *
5
+     * Copyright (C) 2016, Some right reserved.
6
+     *
7
+     * @author Kacper "Kadet" Donat <[email protected]>
8
+     *
9
+     * Contact with author:
10
+     * Xmpp: [email protected]
11
+     * E-mail: [email protected]
12
+     *
13
+     * From Kadet with love.
14
+     */
15 15
 
16 16
 namespace Kadet\Highlighter\Language;
17 17
 
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
     public function __construct(array $singleLine = null, array $multiLine = null)
32 32
     {
33 33
         $this->singleLine = $singleLine ?: [];
34
-        $this->multiLine  = $multiLine  ?: [];
34
+        $this->multiLine  = $multiLine ?: [];
35 35
     }
36 36
 
37 37
 
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
         $all = [];
50 50
 
51 51
         foreach ($this->multiLine as $name => $comment) {
52
-            $comment = array_map(function ($e) { return preg_quote($e, '/'); }, $comment);
52
+            $comment = array_map(function($e) { return preg_quote($e, '/'); }, $comment);
53 53
 
54 54
             $all[] = [$name, "/{$comment[0]}(.*?){$comment[1]}/ms"];
55 55
         }
Please login to merge, or discard this patch.