Minor tweaks to snapshot warnings

This commit is contained in:
Justin Holguín
2023-09-07 18:00:57 +00:00
committed by GitHub
parent bed9726f78
commit 35a52fd146
3 changed files with 7 additions and 7 deletions

6
dist/index.js generated vendored
View File

@@ -1096,13 +1096,13 @@ function snapshotWarningRecommendation(config, warnings) {
const no_pr_snaps = warnings.includes('No snapshots were found for the head SHA');
const retries_disabled = !config.retry_on_snapshot_warnings;
if (no_pr_snaps && retries_disabled) {
return 'Ensure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings.';
return 'Ensure that dependencies are being submitted on PR branches and consider enabling <em>retry-on-snapshot-warnings</em>.';
}
else if (no_pr_snaps) {
return 'Ensure that dependencies are being submitted on PR branches. Re-running this action after a short time may resolve the issue.';
}
else if (retries_disabled) {
return 'Consider enabling retry-on-snapshot-warnings.';
return 'Consider enabling <em>retry-on-snapshot-warnings</em>.';
}
return 'Re-running this action after a short time may resolve the issue.';
}
@@ -1111,7 +1111,7 @@ function addSnapshotWarnings(config, warnings) {
core.summary.addQuote(`${icons.warning}: ${warnings}`);
const recommendation = snapshotWarningRecommendation(config, warnings);
const docsLink = 'See <a href="https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#best-practices-for-using-the-dependency-review-api-and-the-dependency-submission-api-together">the documentation</a> for more information and troubleshooting advice.';
core.summary.addRaw(`${recommendation} ${docsLink}}`);
core.summary.addRaw(`${recommendation} ${docsLink}`);
}
exports.addSnapshotWarnings = addSnapshotWarnings;
function countLicenseIssues(invalidLicenseChanges) {

2
dist/index.js.map generated vendored

File diff suppressed because one or more lines are too long

View File

@@ -240,11 +240,11 @@ function snapshotWarningRecommendation(
)
const retries_disabled = !config.retry_on_snapshot_warnings
if (no_pr_snaps && retries_disabled) {
return 'Ensure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings.'
return 'Ensure that dependencies are being submitted on PR branches and consider enabling <em>retry-on-snapshot-warnings</em>.'
} else if (no_pr_snaps) {
return 'Ensure that dependencies are being submitted on PR branches. Re-running this action after a short time may resolve the issue.'
} else if (retries_disabled) {
return 'Consider enabling retry-on-snapshot-warnings.'
return 'Consider enabling <em>retry-on-snapshot-warnings</em>.'
}
return 'Re-running this action after a short time may resolve the issue.'
}
@@ -258,7 +258,7 @@ export function addSnapshotWarnings(
const recommendation = snapshotWarningRecommendation(config, warnings)
const docsLink =
'See <a href="https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#best-practices-for-using-the-dependency-review-api-and-the-dependency-submission-api-together">the documentation</a> for more information and troubleshooting advice.'
core.summary.addRaw(`${recommendation} ${docsLink}}`)
core.summary.addRaw(`${recommendation} ${docsLink}`)
}
function countLicenseIssues(