Passed
Push — master ( f0ed0e...da797a )
by Gombos
01:32
created

src/Console/CopyMigrationsCommand.php (2 issues)

Labels
Severity
1
<?php
2
3
namespace Glorand\Model\Settings\Console;
4
5
use Illuminate\Console\Command;
1 ignored issue
show
The type Illuminate\Console\Command was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
6
7
class CopyMigrationsCommand extends Command
8
{
9
    /** @var string */
10
    protected $signature = 'model-settings:copy-migrations';
11
12
    /** @var string */
13
    protected $description = 'Copy migrations files from package to app\'s migration folder';
14
15
    public function handle()
16
    {
17
        \File::copyDirectory(__DIR__ . '/../../migrations', database_path('migrations'));
1 ignored issue
show
The function database_path was not found. Maybe you did not declare it correctly or list all dependencies? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

17
        \File::copyDirectory(__DIR__ . '/../../migrations', /** @scrutinizer ignore-call */ database_path('migrations'));
Loading history...
18
19
        $this->info('Migration files copied successfully.');
20
    }
21
}
22