Beispiel #1
0
 protected function needsMigration($path)
 {
     $publisher = $this->package->migrationPublisher();
     $publisher->filesToPublish($path, null);
     $this->registerResources($publisher);
     return $this;
 }
Beispiel #2
0
 protected function backup($file)
 {
     $backupPath = $this->app->make('path.storage') . '/packages/backup/' . $this->package->getName();
     if (!$this->filesystem->isDirectory($backupPath)) {
         $this->filesystem->makeDirectory($backupPath, 0755, true);
     }
     $newFile = $backupPath . '/' . date('Ymdhis') . '_' . basename($file);
     $this->filesystem->move($file, $newFile);
 }