@ganakailabs/cloudeval-cli 0.26.4 → 0.26.6

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.
@@ -38,10 +38,10 @@ import {
38
38
  } from "./chunk-3MIP274G.js";
39
39
  import {
40
40
  Banner
41
- } from "./chunk-HEJJ6LSM.js";
41
+ } from "./chunk-VSBRHLSK.js";
42
42
  import {
43
43
  CLI_VERSION
44
- } from "./chunk-AJJXSTOE.js";
44
+ } from "./chunk-RBJUMR3T.js";
45
45
  import {
46
46
  raisedButtonStyle,
47
47
  terminalTheme
@@ -3,8 +3,8 @@ import {
3
3
  bannerMetaColor,
4
4
  bannerSegmentColor,
5
5
  splitBannerLineSegments
6
- } from "./chunk-HEJJ6LSM.js";
7
- import "./chunk-AJJXSTOE.js";
6
+ } from "./chunk-VSBRHLSK.js";
7
+ import "./chunk-RBJUMR3T.js";
8
8
  import "./chunk-ZDKRIOMB.js";
9
9
  export {
10
10
  Banner,
@@ -1,5 +1,5 @@
1
1
  // src/version.ts
2
- var CLI_VERSION = "0.26.4";
2
+ var CLI_VERSION = "0.26.6";
3
3
 
4
4
  export {
5
5
  CLI_VERSION
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  CLI_VERSION
3
- } from "./chunk-AJJXSTOE.js";
3
+ } from "./chunk-RBJUMR3T.js";
4
4
  import {
5
5
  shouldUseColor,
6
6
  terminalTheme
package/dist/cli.js CHANGED
@@ -36,7 +36,7 @@ import {
36
36
  } from "./chunk-3MIP274G.js";
37
37
  import {
38
38
  CLI_VERSION
39
- } from "./chunk-AJJXSTOE.js";
39
+ } from "./chunk-RBJUMR3T.js";
40
40
 
41
41
  // src/runtime/prepareInk.ts
42
42
  import fs from "fs";
@@ -2485,15 +2485,14 @@ var displayNumber = (value, fallback = "not available") => {
2485
2485
  return number === void 0 ? fallback : String(number);
2486
2486
  };
2487
2487
  var formatMoney = (amount, currency, fallback = "not available") => {
2488
- if (amount === void 0) {
2488
+ const numericAmount = numberFrom(amount);
2489
+ if (numericAmount === void 0) {
2489
2490
  return fallback;
2490
2491
  }
2491
- return [amount, currency].filter(Boolean).join(" ");
2492
+ return currency ? `${numericAmount} ${currency}` : String(numericAmount);
2492
2493
  };
2493
2494
  var formatValidation = (validation) => {
2494
- const policyFailed = displayNumber(
2495
- validation?.policyChecks?.failed ?? validation?.psRule?.failed
2496
- );
2495
+ const policyFailed = displayNumber(validation?.policyChecks?.failed);
2497
2496
  const unitFailed = displayNumber(validation?.unitTests?.failed);
2498
2497
  return `Policy checks ${policyFailed} failed, unit tests ${unitFailed} failed`;
2499
2498
  };
@@ -2534,7 +2533,7 @@ var extractValidation = ({
2534
2533
  preload,
2535
2534
  project
2536
2535
  }) => {
2537
- const psRuleSummary = firstRecord(
2536
+ const policySummary = firstRecord(
2538
2537
  waf?.parsed?.validation_summary,
2539
2538
  waf?.raw?.validation_summary,
2540
2539
  waf?.validation_summary
@@ -2549,17 +2548,11 @@ var extractValidation = ({
2549
2548
  project?.status?.unit_tests
2550
2549
  );
2551
2550
  return {
2552
- psRule: {
2553
- total: numberFrom(psRuleSummary?.total_rules, psRuleSummary?.totalRules, rules.length),
2554
- passed: numberFrom(psRuleSummary?.passed_rules, psRuleSummary?.passedRules),
2555
- failed: numberFrom(psRuleSummary?.failed_rules, psRuleSummary?.failedRules, failedRules.length),
2556
- errors: numberFrom(psRuleSummary?.error_rules, psRuleSummary?.errorRules)
2557
- },
2558
2551
  policyChecks: {
2559
- total: numberFrom(psRuleSummary?.total_rules, psRuleSummary?.totalRules, rules.length),
2560
- passed: numberFrom(psRuleSummary?.passed_rules, psRuleSummary?.passedRules),
2561
- failed: numberFrom(psRuleSummary?.failed_rules, psRuleSummary?.failedRules, failedRules.length),
2562
- errors: numberFrom(psRuleSummary?.error_rules, psRuleSummary?.errorRules)
2552
+ total: numberFrom(policySummary?.total_rules, policySummary?.totalRules, rules.length),
2553
+ passed: numberFrom(policySummary?.passed_rules, policySummary?.passedRules),
2554
+ failed: numberFrom(policySummary?.failed_rules, policySummary?.failedRules, failedRules.length),
2555
+ errors: numberFrom(policySummary?.error_rules, policySummary?.errorRules)
2563
2556
  },
2564
2557
  unitTests: {
2565
2558
  status: unitSummary?.status,
@@ -2682,11 +2675,11 @@ var evaluateGate = ({
2682
2675
  failures.push(`${pillar.label} score ${pillar.score} is below ${pillar.threshold}`);
2683
2676
  }
2684
2677
  }
2685
- const failedPsRules = validation.psRule.failed ?? 0;
2678
+ const failedPolicyChecks = validation.policyChecks.failed ?? 0;
2686
2679
  const failedUnitTests = validation.unitTests.failed ?? 0;
2687
- if (gateConfig.failOnValidationErrors && (failedPsRules > 0 || failedUnitTests > 0)) {
2680
+ if (gateConfig.failOnValidationErrors && (failedPolicyChecks > 0 || failedUnitTests > 0)) {
2688
2681
  failures.push(
2689
- `validation has ${failedPsRules} failed policy checks and ${failedUnitTests} failed unit tests`
2682
+ `validation has ${failedPolicyChecks} failed policy checks and ${failedUnitTests} failed unit tests`
2690
2683
  );
2691
2684
  }
2692
2685
  if (gateConfig.maxMonthlyCost !== void 0 && monthlyCost !== void 0 && monthlyCost > gateConfig.maxMonthlyCost) {
@@ -14967,7 +14960,7 @@ program.command("tui").description("Open the CloudEval Terminal UI").option(
14967
14960
  const { assertSecureBaseUrl } = await import("./dist-QLN52XKY.js");
14968
14961
  const [{ render }, { App }] = await Promise.all([
14969
14962
  import("ink"),
14970
- import("./App-SM7XELZQ.js")
14963
+ import("./App-AH7TVME7.js")
14971
14964
  ]);
14972
14965
  const baseUrl = await resolveBaseUrl(options, command);
14973
14966
  assertSecureBaseUrl(baseUrl);
@@ -15025,7 +15018,7 @@ program.command("chat").description("Start an interactive chat session").option(
15025
15018
  const { assertSecureBaseUrl } = await import("./dist-QLN52XKY.js");
15026
15019
  const [{ render }, { App }] = await Promise.all([
15027
15020
  import("ink"),
15028
- import("./App-SM7XELZQ.js")
15021
+ import("./App-AH7TVME7.js")
15029
15022
  ]);
15030
15023
  const baseUrl = await resolveBaseUrl(options, command);
15031
15024
  assertSecureBaseUrl(baseUrl);
@@ -15779,7 +15772,7 @@ Error: ${errorMsg}
15779
15772
  program.command("banner").description("Preview the startup banner and terminal capabilities").action(async () => {
15780
15773
  const { render } = await import("ink");
15781
15774
  const BannerPreview = React.lazy(async () => ({
15782
- default: (await import("./Banner-T3BVRZV3.js")).Banner
15775
+ default: (await import("./Banner-LT4SYNKO.js")).Banner
15783
15776
  }));
15784
15777
  render(
15785
15778
  /* @__PURE__ */ jsx(React.Suspense, { fallback: null, children: /* @__PURE__ */ jsx(BannerPreview, { disable: false }) })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ganakailabs/cloudeval-cli",
3
- "version": "0.26.4",
3
+ "version": "0.26.6",
4
4
  "license": "LicenseRef-CloudEval-CLI",
5
5
  "type": "module",
6
6
  "description": "CloudEval CLI for cloud architecture, cost, report, automation, and MCP workflows.",
package/sbom.spdx.json CHANGED
@@ -14,7 +14,7 @@
14
14
  {
15
15
  "SPDXID": "SPDXRef-Package-CloudEval-CLI",
16
16
  "name": "CloudEval CLI",
17
- "versionInfo": "0.26.4",
17
+ "versionInfo": "0.26.6",
18
18
  "downloadLocation": "https://github.com/ganakailabs/cloudeval-cli",
19
19
  "filesAnalyzed": false,
20
20
  "licenseConcluded": "LicenseRef-CloudEval-CLI",