Passed
Push — master ( 43c31c...dc0566 )
by Alexander
03:03
created

KeyGenerateCommand::execute()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 2
Code Lines 0

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 0
nc 1
nop 2
dl 0
loc 2
rs 10
c 1
b 0
f 0
1
<?php
2
3
/**
4
 * Lenevor Framework
5
 *
6
 * LICENSE
7
 *
8
 * This source file is subject to the new BSD license that is bundled
9
 * with this package in the file license.md.
10
 * It is also available through the world-wide-web at this URL:
11
 * https://lenevor.com/license
12
 * If you did not receive a copy of the license and are unable to
13
 * obtain it through the world-wide-web, please send an email
14
 * to [email protected] so we can send you a copy immediately.
15
 *
16
 * @package     Lenevor
17
 * @subpackage  Base
18
 * @link        https://lenevor.com
19
 * @copyright   Copyright (c) 2019 - 2023 Alexander Campo <[email protected]>
20
 * @license     https://opensource.org/licenses/BSD-3-Clause New BSD license or see https://lenevor.com/license or see /license.md
21
 */
22
23
namespace Syscodes\Components\Core\Console\Commands;
24
25
use Syscodes\Components\Console\Command\Command;
26
use Syscodes\Components\Console\Input\InputOption;
27
use Syscodes\Components\Contracts\Console\Input\Input as InputInterface;
28
use Syscodes\Components\Contracts\Console\Output\Output as OutputInterface;
29
use Syscodes\Components\Contracts\Console\Input\InputOption as InputOptionInterface;
30
31
/**
32
 * This class displays the key generate for a given command.
33
 */
34
class KeyGenerateCommand extends Command
35
{
36
    /**
37
     * Gets input definition for command.
38
     * 
39
     * @return void
40
     */
41
    protected function define()
42
    {
43
        $this
44
            ->setName('key:generate')
45
            ->setDefinition([
46
                new InputOption('show', null, InputOptionInterface::VALUE_REQUIRED, 'Display the key instead of modifying files'),
47
            ])
48
            ->setDescription('Set the application key');
49
    }
50
51
    /**
52
     * Executes the current command.
53
     * 
54
     * @param  \Syscodes\Components\Contracts\Console\Input\Input  $input
55
     * @param  \Syscodes\Components\Contracts\Console\Output\Output  $input
56
     * 
57
     * @return int|mixed
58
     * 
59
     * @throws \LogicException
60
     */
61
    protected function execute(InputInterface $input, OutputInterface $output) 
62
    {
63
64
    }
65
}