Compare commits
No commits in common. "1cf2dc3d86ecff354dbb0ea559316ba605acfee3" and "bcf8b6621b8cbd1007fa18bd462a9ecedcf69e75" have entirely different histories.
1cf2dc3d86
...
bcf8b6621b
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "Kernel",
|
||||
"version": "0.1.1",
|
||||
"version": "0.2",
|
||||
"author": "ITGuild",
|
||||
"slug": "kernel",
|
||||
"type": "kernel",
|
||||
|
@ -15,7 +15,7 @@ $form->field(\itguild\forms\inputs\Select::class, "files[]", [
|
||||
])
|
||||
->setLabel("Дополнительные файлы")
|
||||
->setOptions([
|
||||
'env.example' => 'env.example',
|
||||
'.env.example' => '.env.example',
|
||||
'bootstrap.php' => 'bootstrap',
|
||||
'composer.json' => 'composer.json',
|
||||
])
|
||||
|
@ -74,21 +74,18 @@ class KernelService
|
||||
$this->files->copyKernelFolder($tmpKernelDirFull . 'kernel' , ROOT_DIR . "/kernel");
|
||||
|
||||
foreach ($files as $file) {
|
||||
if ($file === 'bootstrap.php') {
|
||||
Debug::prn($file);
|
||||
if ($file === 'bootstrap') {
|
||||
Debug::prn(123);
|
||||
$this->files->recursiveRemoveDir(ROOT_DIR . '/bootstrap');
|
||||
$this->files->copyKernelFolder($tmpKernelDirFull . 'bootstrap' , ROOT_DIR . '/bootstrap');
|
||||
}
|
||||
if ($file === 'env.example') {
|
||||
copy($tmpKernelDirFull . $file , ROOT_DIR . '/.' . $file);
|
||||
chmod(ROOT_DIR . '/.' . $file, 0775);
|
||||
continue;
|
||||
}
|
||||
copy($tmpKernelDirFull . $file , ROOT_DIR . '/' . $file);
|
||||
chmod(ROOT_DIR . '/' . $file, 0775);
|
||||
}
|
||||
|
||||
$this->files->recursiveRemoveDir($tmpKernelDirFull);
|
||||
unlink(ROOT_DIR . $path);
|
||||
Debug::dd("update kernel success");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user