Test Failed
Branch stable (de20f1)
by Nuno
01:49
created

Installer   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
dl 0
loc 22
rs 10
c 0
b 0
f 0
wmc 1
lcom 0
cbo 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A install() 0 16 1
1
<?php
2
3
namespace LaravelZero\Framework\Commands\Component\Illuminate\filesystem;
4
5
use LaravelZero\Framework\Commands\Component\Installer as InstallCommand;
6
use LaravelZero\Framework\Contracts\Providers\Composer as ComposerContract;
7
use LaravelZero\Framework\Contracts\Commands\Component\Installer as InstallerContract;
8
9
/**
10
 * This is the Zero Framework illuminate/filesystem install class.
11
 *
12
 * @author Nuno Maduro <[email protected]>
13
 */
14
class Installer implements InstallerContract
15
{
16
    /**
17
     * {@inheritdoc}
18
     */
19
    public function install(InstallCommand $command, ComposerContract $composer): bool
20
    {
21
        $command->info('Pulling illuminate/filesystem...');
22
        $composer->require('illuminate/filesystem "5.5.*"');
23
24
        $command->info('Component installed! Usage:');
25
        $command->comment('
26
27
use Illuminate\Support\Facades\File;
28
29
File::put("file.txt", "Thank you for considering Laravel Zero.");
30
31
        ');
32
33
        return true;
34
    }
35
}
36