public function fire()
    {
        $headers = ['File name', 'File path', 'Created at'];
        $backups = ($this->option('latest')) ? [$this->editor->getLatestBackup()] : $this->editor->getBackups();

        if ($this->option('latest')) {
            $latest = $this->editor->getLatestBackup();
            if (! is_null($latest)) {
                $backups = [$latest];
                $total = 1;
            } else {
                $total = 0;
            }
        } else {
            $backups = $this->editor->getBackups();
            $total   = count($backups);
        }

        $this->line('Loading backup files...');
        $this->line('');

        if ($total == 0) {
            $this->info("You have not any backup file");
        } elseif ($total == 1) {
            $this->table($headers, $backups);
            $this->line('');
            $this->info("There is 1 backup file found from your request");
        } else {
            $this->table($headers, $backups);
            $this->line('');
            $this->info("There are {$total} backup files found from your request");
        }
    }
public function fire()
    {
        $headers = ['File name', 'File path', 'Created at'];
        $backups = ($this->option('latest')) ? [$this->editor->getLatestBackup()] : $this->editor->getBackups();

        if ($this->option('latest')) {
            $latest = $this->editor->getLatestBackup();
            if (! is_null($latest)) {
                $backups = [$latest];
                $total = 1;
            } else {
                $total = 0;
            }
        } else {
            $backups = $this->editor->getBackups();
            $total   = count($backups);
        }

        $this->line('Loading backup files...');
        $this->line('');

        if ($total == 0) {
            $this->info("You have not any backup file");
        } elseif ($total == 1) {
            $this->table($headers, $backups);
            $this->line('');
            $this->info("There is 1 backup file found from your request");
        } else {
            $this->table($headers, $backups);
            $this->line('');
            $this->info("There are {$total} backup files found from your request");
        }
    }
public function fire ( ) { $ headers = [ 'File name' , 'File path' , 'Created at' ] ; $ backups = ( $ this -> option ( 'latest' ) ) ? [ $ this -> editor -> getLatestBackup ( ) ] : $ this -> editor -> getBackups ( ) ; if ( $ this -> option ( 'latest' ) ) { $ latest = $ this -> editor -> getLatestBackup ( ) ; if ( ! is_null ( $ latest ) ) { $ backups = [ $ latest ] ; $ total = 1 ; } else { $ total = 0 ; } } else { $ backups = $ this -> editor -> getBackups ( ) ; $ total = count ( $ backups ) ; } $ this -> line ( 'Loading backup files...' ) ; $ this -> line ( '' ) ; if ( $ total == 0 ) { $ this -> info ( "You have not any backup file" ) ; } elseif ( $ total == 1 ) { $ this -> table ( $ headers , $ backups ) ; $ this -> line ( '' ) ; $ this -> info ( "There is 1 backup file found from your request" ) ; } else { $ this -> table ( $ headers , $ backups ) ; $ this -> line ( '' ) ; $ this -> info ( "There are {$total} backup files found from your request" ) ; } }
Execute the console command.

@return mixed
Execute the console command .