mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-22 14:23:57 -07:00
Update install.php
This commit is contained in:
parent
2037c20734
commit
0c7295f28a
1 changed files with 9 additions and 6 deletions
15
install.php
15
install.php
|
@ -50,7 +50,7 @@ function runProcess(string $cmd, string $input = null): void
|
|||
$process = proc_open($cmd, $descriptorSpec, $pipes);
|
||||
|
||||
if (!is_resource($process)) {
|
||||
echo "ERROR - Could not start subprocess.\n";
|
||||
out('- Could not start subprocess', 'error');
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -93,13 +93,13 @@ if (!is_file(ROOT . 'vendor/autoload.php')) {
|
|||
}
|
||||
}
|
||||
// Installing dependencies
|
||||
if (is_file(ROOT . 'composer.phar')) {
|
||||
out('- Installing dependencies...');
|
||||
runProcess('php ' . ROOT . 'composer.phar install --no-interaction --no-ansi');
|
||||
out('- Completed!');
|
||||
} else {
|
||||
if (!is_file(ROOT . 'composer.phar')) {
|
||||
out('- composer.phar not found', 'error');
|
||||
exit;
|
||||
}
|
||||
out('- Installing dependencies...');
|
||||
runProcess('php ' . ROOT . 'composer.phar install --no-interaction --no-ansi');
|
||||
out('- Completed!');
|
||||
}
|
||||
|
||||
// Preparing ENV
|
||||
|
@ -107,3 +107,6 @@ if (is_file(ROOT . '.env.example') && !is_file(ROOT . '.env')) {
|
|||
copy(ROOT . '.env.example', ROOT . '.env');
|
||||
out('- Environment file created!', 'success');
|
||||
}
|
||||
|
||||
// Editing ENV file
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue