diff --git a/kernel/console/controllers/KernelController.php b/kernel/console/controllers/KernelController.php index c59d7f4..147d84f 100644 --- a/kernel/console/controllers/KernelController.php +++ b/kernel/console/controllers/KernelController.php @@ -41,6 +41,14 @@ class KernelController extends ConsoleController $this->out->r("/bootstrap не найден", 'red'); } + if (file_exists(ROOT_DIR . '/bootstrap.php')) { + $tmpBootstrapPhpDirFull = RESOURCES_DIR . '/tmp/ad/kernel/bootstrap.php'; + copy(ROOT_DIR . '/bootstrap.php', $tmpBootstrapPhpDirFull); + $this->out->r("/bootstrap.php скопирован во временную папку", 'green'); + } else { + $this->out->r("/bootstrap.php не найден", 'red'); + } + if (file_exists(ROOT_DIR . '/.env.example')) { $tmpEnvDirFull = RESOURCES_DIR . '/tmp/ad/kernel/env.example'; copy(ROOT_DIR . '/.env.example', $tmpEnvDirFull); @@ -88,6 +96,7 @@ class KernelController extends ConsoleController if (isset($this->argv['bootstrap'])) { $this->files->recursiveRemoveDir(ROOT_DIR . '/bootstrap'); $this->files->copy_folder($tmpKernelDirFull . 'bootstrap' , ROOT_DIR . '/bootstrap'); + copy($tmpKernelDirFull . '/bootstrap.php' , ROOT_DIR . '/bootstrap.php'); } if (isset($this->argv['env'])) { diff --git a/kernel/services/ModuleService.php b/kernel/services/ModuleService.php index 80b140c..79e023e 100644 --- a/kernel/services/ModuleService.php +++ b/kernel/services/ModuleService.php @@ -346,7 +346,7 @@ class ModuleService $fileHelper->copy_folder(APP_DIR . '/modules/' . $moduleName, $tmpModuleDirFull . 'app/'); $fileHelper->copy_folder(KERNEL_APP_MODULES_DIR . '/' . $moduleName, $tmpModuleDirFull . 'kernel/'); - if (!is_dir(RESOURCES_DIR . '/tmp/module')) { + if (!is_dir(RESOURCES_DIR . '/tmp/modules')) { mkdir(RESOURCES_DIR . '/tmp/modules', 0777, true); } $fileHelper->pack($tmpModuleDirFull, RESOURCES_DIR . '/tmp/modules/' . $moduleName . '.itguild');