Completed
Pull Request — master (#17)
by Rougin
14:40
created
src/Commands/MakeViewCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -40,11 +40,11 @@
 block discarded – undo
40 40
         $contents = (new DataGenerator($this->describe, $input))->generate();
41 41
         $filename = strtolower(plural(underscore($input->getArgument('table'))));
42 42
 
43
-        $views = [ 'create', 'edit', 'index', 'show' ];
43
+        $views = ['create', 'edit', 'index', 'show'];
44 44
 
45 45
         foreach ($views as $item) {
46
-            $file = 'application/views/' . $filename . '/' . $item . '.php';
47
-            $view = $this->renderer->render('Views/' . ucfirst($item) . '.twig', $contents);
46
+            $file = 'application/views/'.$filename.'/'.$item.'.php';
47
+            $view = $this->renderer->render('Views/'.ucfirst($item).'.twig', $contents);
48 48
 
49 49
             $this->filesystem->write($file, $view);
50 50
         }
Please login to merge, or discard this patch.
src/Commands/MakeControllerCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
         $filename  = ucfirst(plural(underscore($input->getArgument('table'))));
42 42
         $rendered  = $this->renderer->render('Controller.twig', $contents);
43 43
 
44
-        $this->filesystem->write('application/controllers/' . $filename . '.php', $rendered);
44
+        $this->filesystem->write('application/controllers/'.$filename.'.php', $rendered);
45 45
 
46 46
         $output->writeln('<info>Controller created successfully!</info>');
47 47
     }
Please login to merge, or discard this patch.
src/Common/InflectorExtension.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -18,10 +18,10 @@
 block discarded – undo
18 18
     public function getFilters()
19 19
     {
20 20
         return array(
21
-            'plural'     => new \Twig_SimpleFilter('plural', [ $this, 'toPluralFormat' ]),
22
-            'singular'   => new \Twig_SimpleFilter('singular', [ $this, 'toSingularFormat' ]),
23
-            'title'      => new \Twig_SimpleFilter('title', [ $this, 'toTitleCase' ]),
24
-            'underscore' => new \Twig_SimpleFilter('underscore', [ $this, 'toUnderscoreCase' ]),
21
+            'plural'     => new \Twig_SimpleFilter('plural', [$this, 'toPluralFormat']),
22
+            'singular'   => new \Twig_SimpleFilter('singular', [$this, 'toSingularFormat']),
23
+            'title'      => new \Twig_SimpleFilter('title', [$this, 'toTitleCase']),
24
+            'underscore' => new \Twig_SimpleFilter('underscore', [$this, 'toUnderscoreCase']),
25 25
         );
26 26
     }
27 27
 
Please login to merge, or discard this patch.
src/Commands/MakeModelCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -38,12 +38,12 @@
 block discarded – undo
38 38
      */
39 39
     protected function execute(InputInterface $input, OutputInterface $output)
40 40
     {
41
-        $modelType = 'Models/' . ucfirst($input->getOption('type'));
41
+        $modelType = 'Models/'.ucfirst($input->getOption('type'));
42 42
         $contents  = (new DataGenerator($this->describe, $input))->generate();
43 43
         $filename  = ucfirst(singular(underscore($input->getArgument('table'))));
44
-        $rendered  = $this->renderer->render($modelType . '.twig', $contents);
44
+        $rendered  = $this->renderer->render($modelType.'.twig', $contents);
45 45
 
46
-        $this->filesystem->write('application/models/' . $filename . '.php', $rendered);
46
+        $this->filesystem->write('application/models/'.$filename.'.php', $rendered);
47 47
 
48 48
         $output->writeln('<info>Model created successfully!</info>');
49 49
     }
Please login to merge, or discard this patch.
src/Combustor.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
      */
36 36
     public static function boot($filename = 'combustor.yml', \Auryn\Injector $injector = null, $directory = null)
37 37
     {
38
-        $directory = __DIR__ . '/../build'; // TEST DIRECTORY
38
+        $directory = __DIR__.'/../build'; // TEST DIRECTORY
39 39
 
40 40
         \Rougin\SparkPlug\Instance::create($directory);
41 41
 
@@ -54,13 +54,13 @@  discard block
 block discarded – undo
54 54
      */
55 55
     protected static function prepareDependencies()
56 56
     {
57
-        require APPPATH . 'config/database.php';
57
+        require APPPATH.'config/database.php';
58 58
 
59 59
         if (is_dir('vendor/rougin/codeigniter/src/')) {
60 60
             $basePath = 'vendor/rougin/codeigniter/src/';
61 61
         }
62 62
 
63
-        require $basePath . 'helpers/inflector_helper.php';
63
+        require $basePath.'helpers/inflector_helper.php';
64 64
 
65 65
         $driver = new \Rougin\Describe\Driver\CodeIgniterDriver($db[$active_group]);
66 66
 
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
      */
75 75
     protected static function prepareTemplates()
76 76
     {
77
-        $extensions = [ new \Rougin\Combustor\Common\InflectorExtension ];
77
+        $extensions = [new \Rougin\Combustor\Common\InflectorExtension];
78 78
 
79 79
         $template = self::$application->getTemplatePath();
80 80
 
Please login to merge, or discard this patch.
src/Commands/MakeScaffoldCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,10 +38,10 @@
 block discarded – undo
38 38
      */
39 39
     protected function execute(InputInterface $input, OutputInterface $output)
40 40
     {
41
-        $commands = [ 'make:controller', 'make:model', 'make:view' ];
41
+        $commands = ['make:controller', 'make:model', 'make:view'];
42 42
 
43 43
         foreach ($commands as $command) {
44
-            $arguments  = [ 'command' => $command, 'table' => $input->getArgument('table') ];
44
+            $arguments = ['command' => $command, 'table' => $input->getArgument('table')];
45 45
 
46 46
             if ($command == 'make:model') {
47 47
                 $arguments['--type'] = $input->getOption('type');
Please login to merge, or discard this patch.