Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
recca0120 committed Mar 2, 2018
1 parent af6c48d commit 5e04107
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 25 deletions.
4 changes: 2 additions & 2 deletions src/Application.php
Expand Up @@ -3,8 +3,8 @@
namespace Recca0120\Terminal;

use Illuminate\Http\Request;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\StringInput;
use Recca0120\Terminal\Contracts\TerminalCommand;
use Symfony\Component\Console\Output\BufferedOutput;
use Symfony\Component\Console\Formatter\OutputFormatter;
use Illuminate\Console\Application as ConsoleApplication;
Expand Down Expand Up @@ -49,7 +49,7 @@ public function call($command, array $parameters = [], $outputBuffer = null)
public function resolveCommands($commands)
{
return parent::resolveCommands(array_filter($commands, function ($command) {
return is_subclass_of($command, WebCommand::class);
return is_subclass_of($command, TerminalCommand::class);
}));
}

Expand Down
4 changes: 1 addition & 3 deletions src/Console/Commands/Artisan.php
Expand Up @@ -3,13 +3,11 @@
namespace Recca0120\Terminal\Console\Commands;

use InvalidArgumentException;
use Illuminate\Console\Command;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\StringInput;
use Illuminate\Contracts\Console\Kernel as ArtisanContract;

class Artisan extends Command implements WebCommand
class Artisan extends Command
{
/**
* The console command name.
Expand Down
4 changes: 1 addition & 3 deletions src/Console/Commands/ArtisanTinker.php
Expand Up @@ -2,11 +2,9 @@

namespace Recca0120\Terminal\Console\Commands;

use Illuminate\Console\Command;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\InputOption;

class ArtisanTinker extends Command implements WebCommand
class ArtisanTinker extends Command
{
/**
* The console command name.
Expand Down
4 changes: 1 addition & 3 deletions src/Console/Commands/Cleanup.php
Expand Up @@ -3,12 +3,10 @@
namespace Recca0120\Terminal\Console\Commands;

use Webmozart\Glob\Glob;
use Illuminate\Console\Command;
use Illuminate\Support\Collection;
use Illuminate\Filesystem\Filesystem;
use Recca0120\Terminal\Contracts\WebCommand;

class Cleanup extends Command implements WebCommand
class Cleanup extends Command
{
/**
* The console command name.
Expand Down
10 changes: 10 additions & 0 deletions src/Console/Commands/Command.php
@@ -0,0 +1,10 @@
<?php

namespace Recca0120\Terminal\Console\Commands;

use Illuminate\Console\Command as BaseCommand;
use Recca0120\Terminal\Contracts\TerminalCommand;

class Command extends BaseCommand implements TerminalCommand
{
}
4 changes: 1 addition & 3 deletions src/Console/Commands/Composer.php
Expand Up @@ -3,13 +3,11 @@
namespace Recca0120\Terminal\Console\Commands;

use Phar;
use Illuminate\Console\Command;
use Illuminate\Filesystem\Filesystem;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\StringInput;

class Composer extends Command implements WebCommand
class Composer extends Command
{
/**
* The console command name.
Expand Down
4 changes: 1 addition & 3 deletions src/Console/Commands/Find.php
Expand Up @@ -3,17 +3,15 @@
namespace Recca0120\Terminal\Console\Commands;

use Exception;
use Illuminate\Console\Command;
use Symfony\Component\Finder\Finder;
use Illuminate\Filesystem\Filesystem;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\StringInput;
use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;

class Find extends Command implements WebCommand
class Find extends Command
{
/**
* The console command name.
Expand Down
4 changes: 1 addition & 3 deletions src/Console/Commands/Mysql.php
Expand Up @@ -3,12 +3,10 @@
namespace Recca0120\Terminal\Console\Commands;

use Illuminate\Support\Arr;
use Illuminate\Console\Command;
use Illuminate\Database\DatabaseManager;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\InputOption;

class Mysql extends Command implements WebCommand
class Mysql extends Command
{
/**
* The console command name.
Expand Down
3 changes: 1 addition & 2 deletions src/Console/Commands/Tail.php
Expand Up @@ -5,11 +5,10 @@
use Illuminate\Console\Command;
use Illuminate\Support\Collection;
use Illuminate\Filesystem\Filesystem;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\InputArgument;

class Tail extends Command implements WebCommand
class Tail extends Command
{
/**
* The console command name.
Expand Down
3 changes: 1 addition & 2 deletions src/Console/Commands/Vi.php
Expand Up @@ -4,11 +4,10 @@

use Illuminate\Console\Command;
use Illuminate\Filesystem\Filesystem;
use Recca0120\Terminal\Contracts\WebCommand;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\InputArgument;

class Vi extends Command implements WebCommand
class Vi extends Command
{
/**
* The console command name.
Expand Down
Expand Up @@ -2,6 +2,6 @@

namespace Recca0120\Terminal\Contracts;

interface WebCommand
interface TerminalCommand
{
}

0 comments on commit 5e04107

Please sign in to comment.