@socketsecurity/cli-with-sentry 1.0.105 → 1.0.106

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 CHANGED
@@ -1626,7 +1626,7 @@ async function performReachabilityAnalysis(options) {
1626
1626
  // Build Coana arguments.
1627
1627
  const coanaArgs = ['run', cwd, '--output-dir', cwd, '--socket-mode', constants.DOT_SOCKET_DOT_FACTS_JSON, '--disable-report-submission', ...(reachabilityOptions.reachAnalysisTimeout ? ['--analysis-timeout', `${reachabilityOptions.reachAnalysisTimeout}`] : []), ...(reachabilityOptions.reachAnalysisMemoryLimit ? ['--memory-limit', `${reachabilityOptions.reachAnalysisMemoryLimit}`] : []), ...(reachabilityOptions.reachDisableAnalytics ? ['--disable-analytics-sharing'] : []), ...(tarHash ? ['--run-without-docker', '--manifests-tar-hash', tarHash] : []),
1628
1628
  // Empty reachEcosystems implies scanning all ecosystems.
1629
- ...(reachabilityOptions.reachEcosystems.length ? ['--purl-types', ...reachabilityOptions.reachEcosystems] : []), ...(reachabilityOptions.reachExcludePaths.length ? ['--exclude-dirs', ...reachabilityOptions.reachExcludePaths] : [])];
1629
+ ...(reachabilityOptions.reachEcosystems.length ? ['--purl-types', ...reachabilityOptions.reachEcosystems] : []), ...(reachabilityOptions.reachExcludePaths.length ? ['--exclude-dirs', ...reachabilityOptions.reachExcludePaths] : []), ...(reachabilityOptions.reachSkipCache ? ['--skip-cache-usage'] : [])];
1630
1630
 
1631
1631
  // Build environment variables.
1632
1632
  const env = {
@@ -2326,6 +2326,7 @@ async function handleCi(autoManifest) {
2326
2326
  reachDisableAnalytics: false,
2327
2327
  reachEcosystems: [],
2328
2328
  reachExcludePaths: [],
2329
+ reachSkipCache: false,
2329
2330
  runReachabilityAnalysis: false
2330
2331
  },
2331
2332
  repoName,
@@ -3890,7 +3891,7 @@ async function coanaFix(fixConfig) {
3890
3891
  }
3891
3892
  };
3892
3893
  }
3893
- const fixCResult = await utils.spawnCoana(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, '--apply-fixes-to', ...(isAll ? ['all'] : ghsas), ...fixConfig.unknownFlags], fixConfig.orgSlug, {
3894
+ const fixCResult = await utils.spawnCoana(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, '--apply-fixes-to', ...(isAll ? ['all'] : ghsas), ...(fixConfig.rangeStyle ? ['--range-style', fixConfig.rangeStyle] : []), ...fixConfig.unknownFlags], fixConfig.orgSlug, {
3894
3895
  cwd,
3895
3896
  spinner
3896
3897
  });
@@ -3904,7 +3905,7 @@ async function coanaFix(fixConfig) {
3904
3905
  }
3905
3906
  let ids;
3906
3907
  if (isAll) {
3907
- const foundCResult = await utils.spawnCoana(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, ...fixConfig.unknownFlags], fixConfig.orgSlug, {
3908
+ const foundCResult = await utils.spawnCoana(['compute-fixes-and-upgrade-purls', cwd, '--manifests-tar-hash', tarHash, ...(fixConfig.rangeStyle ? ['--range-style', fixConfig.rangeStyle] : []), ...fixConfig.unknownFlags], fixConfig.orgSlug, {
3908
3909
  cwd,
3909
3910
  spinner
3910
3911
  });
@@ -5131,6 +5132,7 @@ async function handleFix({
5131
5132
  ghsas,
5132
5133
  limit,
5133
5134
  orgSlug,
5135
+ rangeStyle,
5134
5136
  spinner,
5135
5137
  unknownFlags
5136
5138
  }), outputKind);
@@ -11407,6 +11409,11 @@ const reachabilityFlags = {
11407
11409
  type: 'string',
11408
11410
  isMultiple: true,
11409
11411
  description: 'List of paths to exclude from reachability analysis, as either a comma separated value or as multiple flags.'
11412
+ },
11413
+ reachSkipCache: {
11414
+ type: 'boolean',
11415
+ default: false,
11416
+ description: 'Skip caching-based optimizations. By default, the reachability analysis will use cached configurations from previous runs to speed up the analysis.'
11410
11417
  }
11411
11418
  };
11412
11419
 
@@ -11606,6 +11613,7 @@ async function run$c(argv, importMeta, {
11606
11613
  reachAnalysisMemoryLimit,
11607
11614
  reachAnalysisTimeout,
11608
11615
  reachDisableAnalytics,
11616
+ reachSkipCache,
11609
11617
  readOnly,
11610
11618
  setAsAlertsPage: pendingHeadFlag,
11611
11619
  tmp
@@ -11731,7 +11739,7 @@ async function run$c(argv, importMeta, {
11731
11739
  const isUsingNonDefaultMemoryLimit = reachAnalysisMemoryLimit !== reachabilityFlags['reachAnalysisMemoryLimit']?.default;
11732
11740
  const isUsingNonDefaultTimeout = reachAnalysisTimeout !== reachabilityFlags['reachAnalysisTimeout']?.default;
11733
11741
  const isUsingNonDefaultAnalytics = reachDisableAnalytics !== reachabilityFlags['reachDisableAnalytics']?.default;
11734
- const isUsingAnyReachabilityFlags = isUsingNonDefaultMemoryLimit || isUsingNonDefaultTimeout || isUsingNonDefaultAnalytics || hasReachEcosystems || hasReachExcludePaths;
11742
+ const isUsingAnyReachabilityFlags = isUsingNonDefaultMemoryLimit || isUsingNonDefaultTimeout || isUsingNonDefaultAnalytics || hasReachEcosystems || hasReachExcludePaths || reachSkipCache;
11735
11743
  const wasValidInput = utils.checkCommandInput(outputKind, {
11736
11744
  nook: true,
11737
11745
  test: !!orgSlug,
@@ -11793,7 +11801,8 @@ async function run$c(argv, importMeta, {
11793
11801
  reachAnalysisTimeout: Number(reachAnalysisTimeout),
11794
11802
  reachAnalysisMemoryLimit: Number(reachAnalysisMemoryLimit),
11795
11803
  reachEcosystems,
11796
- reachExcludePaths
11804
+ reachExcludePaths,
11805
+ reachSkipCache: Boolean(reachSkipCache)
11797
11806
  },
11798
11807
  readOnly: Boolean(readOnly),
11799
11808
  repoName,
@@ -12440,7 +12449,8 @@ async function scanOneRepo(repoSlug, {
12440
12449
  reachAnalysisTimeout: 0,
12441
12450
  reachAnalysisMemoryLimit: 0,
12442
12451
  reachEcosystems: [],
12443
- reachExcludePaths: []
12452
+ reachExcludePaths: [],
12453
+ reachSkipCache: false
12444
12454
  },
12445
12455
  readOnly: false,
12446
12456
  repoName: repoSlug,
@@ -13670,7 +13680,8 @@ async function run$6(argv, importMeta, {
13670
13680
  org: orgFlag,
13671
13681
  reachAnalysisMemoryLimit,
13672
13682
  reachAnalysisTimeout,
13673
- reachDisableAnalytics
13683
+ reachDisableAnalytics,
13684
+ reachSkipCache
13674
13685
  } = cli.flags;
13675
13686
  const dryRun = !!cli.flags['dryRun'];
13676
13687
 
@@ -13734,7 +13745,8 @@ async function run$6(argv, importMeta, {
13734
13745
  reachAnalysisMemoryLimit: Number(reachAnalysisMemoryLimit),
13735
13746
  reachDisableAnalytics: Boolean(reachDisableAnalytics),
13736
13747
  reachEcosystems,
13737
- reachExcludePaths
13748
+ reachExcludePaths,
13749
+ reachSkipCache: Boolean(reachSkipCache)
13738
13750
  }
13739
13751
  });
13740
13752
  }
@@ -15525,5 +15537,5 @@ void (async () => {
15525
15537
  await utils.captureException(e);
15526
15538
  }
15527
15539
  })();
15528
- //# debugId=4aa5144b-0661-4dab-a2f9-048f567608a4
15540
+ //# debugId=c64e79fd-76d1-44bb-917b-fff778650c74
15529
15541
  //# sourceMappingURL=cli.js.map