mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-02-20 00:33:45 +01:00
Merge remote changes with PR feedback
Combined jbtronics' debug mode handling for composer install with our yarn install/build steps and BackupManager refactoring.
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
"ext-intl": "*",
|
||||
"ext-json": "*",
|
||||
"ext-mbstring": "*",
|
||||
"ext-zip": "*",
|
||||
"amphp/http-client": "^5.1",
|
||||
"api-platform/doctrine-orm": "^4.1",
|
||||
"api-platform/json-api": "^4.0.0",
|
||||
|
||||
@@ -55,6 +55,8 @@ class UpdateExecutor
|
||||
private readonly InstallationTypeDetector $installationTypeDetector,
|
||||
private readonly VersionManagerInterface $versionManager,
|
||||
private readonly BackupManager $backupManager,
|
||||
#[Autowire(param: 'app.debug_mode')]
|
||||
private readonly bool $debugMode = false,
|
||||
) {
|
||||
}
|
||||
|
||||
@@ -368,13 +370,23 @@ class UpdateExecutor
|
||||
|
||||
// Step 7: Install PHP dependencies
|
||||
$stepStart = microtime(true);
|
||||
$this->runCommand([
|
||||
'composer', 'install',
|
||||
'--no-dev',
|
||||
'--optimize-autoloader',
|
||||
'--no-interaction',
|
||||
'--no-progress',
|
||||
], 'Install PHP dependencies', 600);
|
||||
if ($this->debugMode) {
|
||||
$this->runCommand([ // Install with dev dependencies in debug mode
|
||||
'composer',
|
||||
'install',
|
||||
'--no-interaction',
|
||||
'--no-progress',
|
||||
], 'Install PHP dependencies', 600);
|
||||
} else {
|
||||
$this->runCommand([
|
||||
'composer',
|
||||
'install',
|
||||
'--no-dev',
|
||||
'--optimize-autoloader',
|
||||
'--no-interaction',
|
||||
'--no-progress',
|
||||
], 'Install PHP dependencies', 600);
|
||||
}
|
||||
$log('composer', 'Installed/updated PHP dependencies', true, microtime(true) - $stepStart);
|
||||
|
||||
// Step 8: Install frontend dependencies
|
||||
|
||||
Reference in New Issue
Block a user