@cleartrip/frontguard 0.2.4 → 0.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +10 -8
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
- package/templates/bitbucket-pipelines.yml +89 -17
- package/templates/freekit-ci-setup.md +4 -2
package/dist/cli.js
CHANGED
|
@@ -2524,13 +2524,17 @@ function bitbucketDownloadsPageUrl() {
|
|
|
2524
2524
|
if (ws && slug) return `https://bitbucket.org/${ws}/${slug}/downloads/`;
|
|
2525
2525
|
return null;
|
|
2526
2526
|
}
|
|
2527
|
+
var DETAILED_REPORT_LINE = "For detailed check analysis, please open the full interactive report:";
|
|
2527
2528
|
function formatBitbucketPrSnippet(report) {
|
|
2528
2529
|
const publicReport = process.env.FRONTGUARD_PUBLIC_REPORT_URL?.trim();
|
|
2529
2530
|
const linkOnly = process.env.FRONTGUARD_BITBUCKET_COMMENT_LINK_ONLY === "1";
|
|
2530
2531
|
const imgMd = checksImageMarkdown();
|
|
2531
2532
|
if (linkOnly && publicReport) {
|
|
2532
2533
|
const parts = [];
|
|
2533
|
-
if (imgMd)
|
|
2534
|
+
if (imgMd) {
|
|
2535
|
+
parts.push(imgMd, "");
|
|
2536
|
+
parts.push(DETAILED_REPORT_LINE);
|
|
2537
|
+
}
|
|
2534
2538
|
parts.push(publicReport.endsWith("\n") ? publicReport.slice(0, -1) : publicReport);
|
|
2535
2539
|
return `${parts.join("\n")}
|
|
2536
2540
|
`;
|
|
@@ -2559,15 +2563,13 @@ function formatBitbucketPrSnippet(report) {
|
|
|
2559
2563
|
""
|
|
2560
2564
|
);
|
|
2561
2565
|
if (publicReport) {
|
|
2562
|
-
out.push("Full interactive report (open in browser):");
|
|
2563
|
-
out.push(publicReport);
|
|
2564
|
-
out.push("");
|
|
2565
2566
|
if (imgMd) {
|
|
2566
|
-
out.push(
|
|
2567
|
-
|
|
2568
|
-
);
|
|
2569
|
-
out.push("");
|
|
2567
|
+
out.push(DETAILED_REPORT_LINE);
|
|
2568
|
+
} else {
|
|
2569
|
+
out.push("Full interactive report (open in browser):");
|
|
2570
2570
|
}
|
|
2571
|
+
out.push(publicReport);
|
|
2572
|
+
out.push("");
|
|
2571
2573
|
} else if (downloadsName && downloadsPage) {
|
|
2572
2574
|
out.push("HTML report is in Repository \u2192 Downloads. Open this page while logged in:");
|
|
2573
2575
|
out.push(downloadsPage);
|