Compare commits

...

2 Commits

Author SHA1 Message Date
Kévin Dunglas
15905c063a fix: use apt-get instead of apt 2023-08-22 09:59:47 +08:00
Kévin Dunglas
4c46f6a762 fix: error when source doesn't exist 2023-08-22 09:56:47 +08:00
3 changed files with 8 additions and 2 deletions

View File

@ -37,7 +37,7 @@ class LinuxMuslCheck
public function fixMusl(array $distro): bool
{
$install_cmd = match ($distro['dist']) {
'ubuntu', 'debian' => 'apt install musl musl-tools -y',
'ubuntu', 'debian' => 'apt-get install musl musl-tools -y',
'alpine' => 'apk add musl musl-utils musl-dev',
default => throw new RuntimeException('Current linux distro is not supported for auto-install musl packages'),
};

View File

@ -77,7 +77,7 @@ class LinuxToolCheckList
public function fixBuildTools(array $distro, array $missing): bool
{
$install_cmd = match ($distro['dist']) {
'ubuntu', 'debian' => 'apt install -y',
'ubuntu', 'debian' => 'apt-get install -y',
'alpine' => 'apk add',
default => throw new RuntimeException('Current linux distro is not supported for auto-install musl packages'),
};

View File

@ -253,6 +253,12 @@ class Downloader
$source = Config::getSource($name);
}
if ($source === null) {
logger()->warning('Source {name} unknown. Skipping.', ['name' => $name]);
return;
}
// load lock file
if (!file_exists(DOWNLOAD_PATH . '/.lock.json')) {
$lock = [];