/**
  * Fire off the handler.
  *
  * @param \Aindong\Pluggables\Console\PluggableMakeCommand $console
  * @param string                                           $slug
  *
  * @return bool
  */
 public function fire(Command $console, $slug)
 {
     $this->console = $console;
     $this->slug = strtolower($slug);
     $this->name = Str::studly($slug);
     if ($this->pluggable->exists($this->slug)) {
         $console->comment('Pluggable [{$this->name}] already exists.');
         return false;
     }
     $this->generate($console);
 }
 /**
  * Fire off the handler.
  *
  * @param \Aindong\Pluggables\Console\PluggableMakeMigrationCommand $console
  * @param string                                                    $slug
  *
  * @return string
  */
 public function fire(Command $console, $slug, $table)
 {
     $this->console = $console;
     $this->pluggableName = Str::studly($slug);
     $this->table = strtolower($table);
     $this->migrationName = snake_case($this->table);
     $this->className = studly_case($this->migrationName);
     if ($this->pluggable->exists($this->pluggableName)) {
         $this->makeFile();
         $this->console->info("Created Pluggable Migration: [{$this->pluggableName}] " . $this->getFilename());
         return exec('composer dump-autoload');
     }
     return $this->console->info("Pluggable [{$this->pluggableName}] does not exist.");
 }