Completed
Push — master ( 8e919b...76847d )
by Andrii
03:06
created
src/controllers/PackageController.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
         $cur = (int) date('Y');
43 43
         $old = (int) $this->year;
44 44
 
45
-        return ($old && $old < $cur ? $this->year . '-' : '') . $cur;
45
+        return ($old && $old < $cur ? $this->year.'-' : '').$cur;
46 46
     }
47 47
 
48 48
     public function getYear()
@@ -57,12 +57,12 @@  discard block
 block discarded – undo
57 57
 
58 58
     public function getIssues()
59 59
     {
60
-        return $this->getItem('issues') ?: ($this->source . '/issues');
60
+        return $this->getItem('issues') ?: ($this->source.'/issues');
61 61
     }
62 62
 
63 63
     public function getWiki()
64 64
     {
65
-        return $this->getItem('wiki') ?: ($this->source . '/wiki');
65
+        return $this->getItem('wiki') ?: ($this->source.'/wiki');
66 66
     }
67 67
 
68 68
     public function getKeywords()
@@ -72,12 +72,12 @@  discard block
 block discarded – undo
72 72
 
73 73
     public function getFullName()
74 74
     {
75
-        return $this->getItem('fullName') ?: ($this->takeVendor()->name . '/' . $this->name);
75
+        return $this->getItem('fullName') ?: ($this->takeVendor()->name.'/'.$this->name);
76 76
     }
77 77
 
78 78
     public function getSource()
79 79
     {
80
-        return $this->getItem('source') ?: ('https://github.com/' . $this->takeGoal('github')->full_name);
80
+        return $this->getItem('source') ?: ('https://github.com/'.$this->takeGoal('github')->full_name);
81 81
     }
82 82
 
83 83
     public function getVersion()
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
 
93 93
     public static function defaultNamespace($vendor, $package)
94 94
     {
95
-        return preg_replace('/[^a-zA-Z0-9\\\\]+/', '', $vendor . strtr("-$package", '-', '\\'));
95
+        return preg_replace('/[^a-zA-Z0-9\\\\]+/', '', $vendor.strtr("-$package", '-', '\\'));
96 96
     }
97 97
 
98 98
     public function getSrc()
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
 
105 105
     public function getHomepage()
106 106
     {
107
-        return $this->getItem('homepage') ?: ($this->isDomain() ? 'http://' . $this->name . '/' : $this->getSource());
107
+        return $this->getItem('homepage') ?: ($this->isDomain() ? 'http://'.$this->name.'/' : $this->getSource());
108 108
     }
109 109
 
110 110
     public function getForum()
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
 
140 140
     public function getRepositoryUrl($file)
141 141
     {
142
-        return 'https://github.com/' . $this->getFullName() . '/blob/master/' . $file;
142
+        return 'https://github.com/'.$this->getFullName().'/blob/master/'.$file;
143 143
     }
144 144
 
145 145
     public function getAuthors()
Please login to merge, or discard this patch.
src/base/BinaryPython.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -49,16 +49,16 @@
 block discarded – undo
49 49
     {
50 50
         $path = parent::detectCommand($path);
51 51
 
52
-        return is_executable($path) ? $path : '/usr/bin/env python ' . $path;
52
+        return is_executable($path) ? $path : '/usr/bin/env python '.$path;
53 53
     }
54 54
 
55 55
     public function install()
56 56
     {
57 57
         if ($this->installer) {
58
-            passthru('/usr/bin/env wget ' . escapeshellarg($this->installer) . ' -O- | /usr/bin/env python', $exitcode);
58
+            passthru('/usr/bin/env wget '.escapeshellarg($this->installer).' -O- | /usr/bin/env python', $exitcode);
59 59
         } elseif ($this->download) {
60
-            $dest = Yii::getAlias('@root/' . $this->name, false);
61
-            passthru('/usr/bin/env wget ' . escapeshellarg($this->download) . ' -O ' . $dest, $exitcode);
60
+            $dest = Yii::getAlias('@root/'.$this->name, false);
61
+            passthru('/usr/bin/env wget '.escapeshellarg($this->download).' -O '.$dest, $exitcode);
62 62
         } else {
63 63
             $args = ['install'];
64 64
             if (!$_SERVER['VIRTUAL_ENV']) {
Please login to merge, or discard this patch.
src/helpers/FileHelper.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
                 unlink($tmp);
45 45
             }
46 46
         }
47
-        Yii::warning('Written file: ' . $path, 'file');
47
+        Yii::warning('Written file: '.$path, 'file');
48 48
 
49 49
         return true;
50 50
     }
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
         $path = rtrim(trim($path), '/');
62 62
         if (!file_exists($path)) {
63 63
             mkdir($path, 0777, true);
64
-            Yii::warning('Created dir:  ' . $path . '/', 'file');
64
+            Yii::warning('Created dir:  '.$path.'/', 'file');
65 65
 
66 66
             return true;
67 67
         }
Please login to merge, or discard this patch.
src/controllers/OwnVersionController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@
 block discarded – undo
25 25
 
26 26
     public function actionMake($version = null)
27 27
     {
28
-        $path = dirname(dirname(__DIR__)) . '/bin/hidev';
28
+        $path = dirname(dirname(__DIR__)).'/bin/hidev';
29 29
         echo "HiDev $this->version $this->date $this->time $this->hash\n";
30 30
         echo "run from $path\n";
31 31
     }
Please login to merge, or discard this patch.
src/components/Interpolator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
                 $this->interpolate($item);
15 15
             }
16 16
         } elseif (is_string($data)) {
17
-            $data = preg_replace_callback('/\\$(\\w+)\\[\'(.+?)\'\\]/', function ($matches) {
17
+            $data = preg_replace_callback('/\\$(\\w+)\\[\'(.+?)\'\\]/', function($matches) {
18 18
                 return $this->get($matches[1], $matches[2]);
19 19
             }, $data);
20 20
         }
Please login to merge, or discard this patch.
src/base/Application.php 3 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -119,7 +119,7 @@
 block discarded – undo
119 119
 
120 120
         foreach (['params', 'aliases', 'modules', 'components'] as $key) {
121 121
             if (isset($config[$key])) {
122
-                $this->{'setExtra' . ucfirst($key)}($config[$key]);
122
+                $this->{'setExtra'.ucfirst($key)}($config[$key]);
123 123
             }
124 124
         }
125 125
 
Please login to merge, or discard this patch.
Doc Comments   +6 added lines, -3 removed lines patch added patch discarded remove patch
@@ -91,6 +91,10 @@  discard block
 block discarded – undo
91 91
         $this->setExtraConfig(static::readVendorConfig($vendor, 'hidev'));
92 92
     }
93 93
 
94
+    /**
95
+     * @param string $vendor
96
+     * @param string $name
97
+     */
94 98
     public function readVendorConfig($vendor, $name)
95 99
     {
96 100
         return static::readConfig(ConfigPlugin::path($vendor, $name));
@@ -98,7 +102,6 @@  discard block
 block discarded – undo
98 102
 
99 103
     /**
100 104
      * Sets extra environment variables.
101
-     * @param array $config
102 105
      */
103 106
     public function setExtraEnv($vars)
104 107
     {
@@ -199,8 +202,8 @@  discard block
 block discarded – undo
199 202
 
200 203
     /**
201 204
      * Run request.
202
-     * @param string|array $query
203
-     * @return Response
205
+     * @param string $query
206
+     * @return \yii\console\Response
204 207
      */
205 208
     public function runRequest($query)
206 209
     {
Please login to merge, or discard this patch.
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -10,12 +10,9 @@
 block discarded – undo
10 10
 
11 11
 namespace hidev\base;
12 12
 
13
-use Exception;
14 13
 use hidev\helpers\ConfigPlugin;
15 14
 use Yii;
16
-use yii\base\InvalidParamException;
17 15
 use yii\base\ViewContextInterface;
18
-use yii\console\Exception as ConsoleException;
19 16
 use yii\helpers\ArrayHelper;
20 17
 
21 18
 /**
Please login to merge, or discard this patch.
src/log/ConsoleTarget.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
         if ($style) {
38 38
             $message = Console::ansiFormat($message, $style);
39 39
         }
40
-        Console::stdout($message . "\n");
40
+        Console::stdout($message."\n");
41 41
     }
42 42
 
43 43
     protected function getContextMessage()
Please login to merge, or discard this patch.
src/config/bootstrap.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -8,24 +8,24 @@
 block discarded – undo
8 8
  * @copyright Copyright (c) 2015-2017, HiQDev (http://hiqdev.com/)
9 9
  */
10 10
 
11
-require_once __DIR__ . '/defines.php';
11
+require_once __DIR__.'/defines.php';
12 12
 
13 13
 if (!defined('HIDEV_VENDOR_DIR')) {
14
-    foreach ([dirname(dirname(__DIR__)) . '/vendor', dirname(dirname(dirname(dirname(__DIR__))))] as $dir) {
15
-        if (file_exists($dir . '/autoload.php')) {
14
+    foreach ([dirname(dirname(__DIR__)).'/vendor', dirname(dirname(dirname(dirname(__DIR__))))] as $dir) {
15
+        if (file_exists($dir.'/autoload.php')) {
16 16
             define('HIDEV_VENDOR_DIR', $dir);
17 17
             break;
18 18
         }
19 19
     }
20 20
 }
21 21
 
22
-if (!defined('HIDEV_VENDOR_DIR') || !file_exists(HIDEV_VENDOR_DIR . '/autoload.php')) {
22
+if (!defined('HIDEV_VENDOR_DIR') || !file_exists(HIDEV_VENDOR_DIR.'/autoload.php')) {
23 23
     fwrite(STDERR, "Run composer to set up dependencies!\n");
24 24
     exit(1);
25 25
 }
26 26
 
27
-require_once HIDEV_VENDOR_DIR . '/autoload.php';
28
-require_once HIDEV_VENDOR_DIR . '/yiisoft/yii2/Yii.php';
27
+require_once HIDEV_VENDOR_DIR.'/autoload.php';
28
+require_once HIDEV_VENDOR_DIR.'/yiisoft/yii2/Yii.php';
29 29
 
30 30
 Yii::setAlias('@hidev', dirname(__DIR__));
31 31
 Yii::setAlias('@vendor', HIDEV_VENDOR_DIR);
Please login to merge, or discard this patch.