Merge pull request #2 from SystemKeeper/extend-informations

chore(log): Log why a PHP version was skipped/used
This commit is contained in:
Robin Appelman 2024-11-25 19:01:05 +01:00 committed by GitHub
commit 578c7d7935
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -165,9 +165,11 @@ function copy(obj) {
version = parseFloat(version.toFixed(1)); version = parseFloat(version.toFixed(1));
if (await isPhpVersionReleased(version)) { if (await isPhpVersionReleased(version)) {
php.push(version.toFixed(1)); php.push(version.toFixed(1));
console.log(`Release for PHP Version ${version.toFixed(1)} exists`);
} else { } else {
// no more minors for this major // no more minors for this major
version = Math.ceil(version) - 0.1; version = Math.ceil(version) - 0.1;
console.log(`No release for PHP Version ${version.toFixed(1)} exists -> skipping`);
} }
} }
php.sort(); php.sort();
@ -178,6 +180,10 @@ function copy(obj) {
if (await distroSupportsPhpVersion(version)) { if (await distroSupportsPhpVersion(version)) {
distroPhp.push(version) distroPhp.push(version)
availablePhp = version; availablePhp = version;
console.log(`Install candidates for PHP Version ${version.toFixed(1)} found`);
} else {
console.log(`No install candidates for PHP version ${version.toFixed(1)} found -> skipping`);
} }
} }