This ensures large allow or deny lists don't create huge comments

This commit is contained in:
Jasper Kamerling
2025-07-30 13:31:26 +02:00
committed by Barry Gordon
parent 6fad417932
commit e3fdf0f899
4 changed files with 34 additions and 12 deletions

6
dist/index.js generated vendored
View File

@@ -1730,13 +1730,13 @@ function addLicensesToSummary(invalidLicenseChanges, config) {
core.summary.addHeading('License Issues', 2);
printLicenseViolations(invalidLicenseChanges);
if (config.allow_licenses && config.allow_licenses.length > 0) {
core.summary.addQuote(`<strong>Allowed Licenses</strong>: ${config.allow_licenses.join(', ')}`);
core.summary.addQuote(`<details><summary><strong>Allowed Licenses</strong>:</summary> ${config.allow_licenses.join(', ')}</details>`);
}
if (config.deny_licenses && config.deny_licenses.length > 0) {
core.summary.addQuote(`<strong>Denied Licenses</strong>: ${config.deny_licenses.join(', ')}`);
core.summary.addQuote(`<details><summary><strong>Denied Licenses</strong>:</summary> ${config.deny_licenses.join(', ')}</details>`);
}
if (config.allow_dependencies_licenses) {
core.summary.addQuote(`<strong>Excluded from license check</strong>: ${config.allow_dependencies_licenses.join(', ')}`);
core.summary.addQuote(`<details><summary><strong>Excluded from license check</strong>:</summary> ${config.allow_dependencies_licenses.join(', ')}</details>`);
}
core.debug(`found ${invalidLicenseChanges.unlicensed.length} unknown licenses`);
core.debug(`${invalidLicenseChanges.unresolved.length} licenses could not be validated`);

2
dist/index.js.map generated vendored

File diff suppressed because one or more lines are too long