mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-14 18:48:21 -07:00
feat(installer): Check Composer
dependencies after installing (#1756)
This commit is contained in:
parent
800e87e7c0
commit
262b8872a5
1 changed files with 10 additions and 1 deletions
11
install.php
11
install.php
|
@ -251,7 +251,7 @@ if (!is_file(BB_ROOT . 'vendor/autoload.php')) {
|
|||
if (is_file(BB_ROOT . 'composer.phar')) {
|
||||
out('- Installing dependencies...', 'info');
|
||||
runProcess('php ' . BB_ROOT . 'composer.phar install --no-interaction --no-ansi');
|
||||
out("- Completed! Composer dependencies are installed!\n", 'success');
|
||||
define('COMPOSER_COMPLETED', true);
|
||||
} else {
|
||||
out('- composer.phar not found. Please, download it (composer.phar) manually', 'error');
|
||||
exit;
|
||||
|
@ -261,6 +261,15 @@ if (!is_file(BB_ROOT . 'vendor/autoload.php')) {
|
|||
out("- Note: Remove 'vendor' folder if you want to re-install dependencies\n");
|
||||
}
|
||||
|
||||
// Check composer dependencies
|
||||
if (defined('COMPOSER_COMPLETED')) {
|
||||
if (is_file(BB_ROOT . 'vendor/autoload.php')) {
|
||||
out("- Completed! Composer dependencies are installed!\n", 'success');
|
||||
} else {
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
// Preparing ENV
|
||||
if (is_file(BB_ROOT . '.env.example') && !is_file(BB_ROOT . '.env')) {
|
||||
if (copy(BB_ROOT . '.env.example', BB_ROOT . '.env')) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue