sonar-sweep 0.2.1 → 0.2.2

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.
@@ -1,3 +1,2 @@
1
- import { t as run } from "../cli-BMrnoS5Q.mjs";
2
-
3
- export { run };
1
+ import { t as run } from "../cli-CXljwzKO.mjs";
2
+ export { run };
@@ -1,26 +1,20 @@
1
- import { a as getPullRequestReport, i as getPullRequestIssues, n as getPullRequestReview, o as SonarCloudClient, r as getPullRequestCoverage, t as transitionIssue } from "./issue-transition-B5r9hQVC.mjs";
1
+ import { a as getPullRequestReport, i as getPullRequestIssues, n as getPullRequestReview, o as SonarCloudClient, r as getPullRequestCoverage, t as transitionIssue } from "./issue-transition-DSFC3zIL.mjs";
2
2
  import { hideBin } from "yargs/helpers";
3
3
  import yargs from "yargs/yargs";
4
4
  import { execFileSync } from "node:child_process";
5
5
  import { existsSync, readFileSync } from "node:fs";
6
6
  import { join } from "node:path";
7
-
8
7
  //#region \0rolldown/runtime.js
9
8
  var __defProp = Object.defineProperty;
10
9
  var __exportAll = (all, no_symbols) => {
11
10
  let target = {};
12
- for (var name in all) {
13
- __defProp(target, name, {
14
- get: all[name],
15
- enumerable: true
16
- });
17
- }
18
- if (!no_symbols) {
19
- __defProp(target, Symbol.toStringTag, { value: "Module" });
20
- }
11
+ for (var name in all) __defProp(target, name, {
12
+ get: all[name],
13
+ enumerable: true
14
+ });
15
+ if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
21
16
  return target;
22
17
  };
23
-
24
18
  //#endregion
25
19
  //#region src/service/hotspot-transition.ts
26
20
  async function reviewHotspot(clientOptions, input) {
@@ -43,7 +37,6 @@ async function reviewHotspot(clientOptions, input) {
43
37
  status: "REVIEWED"
44
38
  };
45
39
  }
46
-
47
40
  //#endregion
48
41
  //#region src/cli/commands/hotspot-review.ts
49
42
  var hotspot_review_exports = /* @__PURE__ */ __exportAll({
@@ -105,7 +98,6 @@ async function handler$6(args) {
105
98
  }
106
99
  process.stdout.write(`Reviewed hotspot ${result.hotspotKey} as ${result.resolution}\n`);
107
100
  }
108
-
109
101
  //#endregion
110
102
  //#region src/cli/commands/issue-accept.ts
111
103
  var issue_accept_exports = /* @__PURE__ */ __exportAll({
@@ -156,7 +148,6 @@ async function handler$5(args) {
156
148
  }
157
149
  process.stdout.write(`Accepted issue ${result.issueKey} (${result.transition})\n`);
158
150
  }
159
-
160
151
  //#endregion
161
152
  //#region src/cli/project-key.ts
162
153
  function resolveProjectKey(projectKey) {
@@ -181,7 +172,6 @@ function getGitRoot() {
181
172
  return process.cwd();
182
173
  }
183
174
  }
184
-
185
175
  //#endregion
186
176
  //#region src/cli/commands/pr-coverage.ts
187
177
  var pr_coverage_exports = /* @__PURE__ */ __exportAll({
@@ -255,7 +245,6 @@ async function handler$4(args) {
255
245
  for (const file of report.files) process.stdout.write(`- ${file.file}: ${file.coverageOnNewCode.toFixed(1)}% (${file.uncoveredLines}/${file.linesToCover} uncovered lines)\n`);
256
246
  process.stdout.write(`See analysis details: ${report.analysisUrl}\n`);
257
247
  }
258
-
259
248
  //#endregion
260
249
  //#region src/service/pr-hotspots.ts
261
250
  async function getPullRequestHotspots(clientOptions, input) {
@@ -297,7 +286,6 @@ function extractFilePath(componentKey, projectKey, componentMap) {
297
286
  if (componentKey.startsWith(prefix)) return componentKey.slice(prefix.length);
298
287
  return componentKey;
299
288
  }
300
-
301
289
  //#endregion
302
290
  //#region src/cli/commands/pr-hotspots.ts
303
291
  var pr_hotspots_exports = /* @__PURE__ */ __exportAll({
@@ -383,7 +371,6 @@ async function handler$3(args) {
383
371
  }
384
372
  process.stdout.write(`See analysis details: ${result.analysisUrl}\n`);
385
373
  }
386
-
387
374
  //#endregion
388
375
  //#region src/cli/commands/pr-issues.ts
389
376
  var pr_issues_exports = /* @__PURE__ */ __exportAll({
@@ -459,7 +446,6 @@ async function handler$2(args) {
459
446
  }
460
447
  process.stdout.write(`See analysis details: ${report.analysisUrl}\n`);
461
448
  }
462
-
463
449
  //#endregion
464
450
  //#region src/cli/commands/pr-report.ts
465
451
  var pr_report_exports = /* @__PURE__ */ __exportAll({
@@ -544,7 +530,6 @@ function formatMetricLabel(metricKey) {
544
530
  default: return metricKey;
545
531
  }
546
532
  }
547
-
548
533
  //#endregion
549
534
  //#region src/cli/commands/pr-review.ts
550
535
  var pr_review_exports = /* @__PURE__ */ __exportAll({
@@ -631,7 +616,6 @@ async function handler(args) {
631
616
  }
632
617
  process.stdout.write(`See analysis details: ${report.analysisUrl}\n`);
633
618
  }
634
-
635
619
  //#endregion
636
620
  //#region src/cli/index.ts
637
621
  async function run(argv = process.argv) {
@@ -645,6 +629,5 @@ async function run(argv = process.argv) {
645
629
  process.exit(1);
646
630
  }).parseAsync();
647
631
  }
648
-
649
632
  //#endregion
650
- export { run as t };
633
+ export { run as t };
package/dist/cli.mjs CHANGED
@@ -1,6 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { t as run } from "./cli-BMrnoS5Q.mjs";
3
-
2
+ import { t as run } from "./cli-CXljwzKO.mjs";
4
3
  //#region src/cli.ts
5
4
  try {
6
5
  await run(process.argv);
@@ -9,6 +8,5 @@ try {
9
8
  process.stderr.write(`${message}\n`);
10
9
  process.exit(1);
11
10
  }
12
-
13
11
  //#endregion
14
- export { };
12
+ export {};
package/dist/index.mjs CHANGED
@@ -1,3 +1,2 @@
1
- import { a as getPullRequestReport, i as getPullRequestIssues, n as getPullRequestReview, o as SonarCloudClient, r as getPullRequestCoverage, t as transitionIssue } from "./issue-transition-B5r9hQVC.mjs";
2
-
3
- export { SonarCloudClient, getPullRequestCoverage, getPullRequestIssues, getPullRequestReport, getPullRequestReview, transitionIssue };
1
+ import { a as getPullRequestReport, i as getPullRequestIssues, n as getPullRequestReview, o as SonarCloudClient, r as getPullRequestCoverage, t as transitionIssue } from "./issue-transition-DSFC3zIL.mjs";
2
+ export { SonarCloudClient, getPullRequestCoverage, getPullRequestIssues, getPullRequestReport, getPullRequestReview, transitionIssue };
@@ -119,7 +119,6 @@ var SonarCloudClient = class {
119
119
  }
120
120
  }
121
121
  };
122
-
123
122
  //#endregion
124
123
  //#region src/service/pr-report.ts
125
124
  async function getPullRequestReport(clientOptions, input) {
@@ -173,7 +172,6 @@ function measureValue(measures, metric) {
173
172
  const parsed = Number.parseFloat(rawValue);
174
173
  return Number.isFinite(parsed) ? parsed : 0;
175
174
  }
176
-
177
175
  //#endregion
178
176
  //#region src/service/pr-issues.ts
179
177
  async function getPullRequestIssues(clientOptions, input) {
@@ -211,7 +209,6 @@ async function getPullRequestIssues(clientOptions, input) {
211
209
  total: response.total
212
210
  };
213
211
  }
214
-
215
212
  //#endregion
216
213
  //#region src/service/pr-coverage.ts
217
214
  async function getPullRequestCoverage(clientOptions, input) {
@@ -246,7 +243,6 @@ function value(measures, metric) {
246
243
  const parsed = Number.parseFloat(raw);
247
244
  return Number.isFinite(parsed) ? parsed : 0;
248
245
  }
249
-
250
246
  //#endregion
251
247
  //#region src/service/pr-review.ts
252
248
  async function getPullRequestReview(clientOptions, input) {
@@ -317,7 +313,6 @@ function makeSnippet(source, issueLine, contextLines) {
317
313
  startLine
318
314
  };
319
315
  }
320
-
321
316
  //#endregion
322
317
  //#region src/service/issue-transition.ts
323
318
  async function transitionIssue(clientOptions, input) {
@@ -333,6 +328,5 @@ async function transitionIssue(clientOptions, input) {
333
328
  transition
334
329
  };
335
330
  }
336
-
337
331
  //#endregion
338
- export { getPullRequestReport as a, getPullRequestIssues as i, getPullRequestReview as n, SonarCloudClient as o, getPullRequestCoverage as r, transitionIssue as t };
332
+ export { getPullRequestReport as a, getPullRequestIssues as i, getPullRequestReview as n, SonarCloudClient as o, getPullRequestCoverage as r, transitionIssue as t };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sonar-sweep",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "CLI for fetching SonarQube Cloud pull request details",
5
5
  "homepage": "https://github.com/clentfort/sonar-sweep#readme",
6
6
  "bugs": {
@@ -38,20 +38,20 @@
38
38
  "prepare": "husky"
39
39
  },
40
40
  "dependencies": {
41
- "yargs": "17.7.2"
41
+ "yargs": "17.7.3"
42
42
  },
43
43
  "devDependencies": {
44
44
  "@nkzw/oxlint-config": "^1.0.1",
45
- "@types/node": "22.13.10",
46
- "@types/yargs": "17.0.33",
45
+ "@types/node": "22.19.21",
46
+ "@types/yargs": "17.0.35",
47
47
  "@typescript/native-preview": "^7.0.0-dev.20260225.1",
48
48
  "husky": "^9.1.7",
49
49
  "npm-run-all2": "^8.0.4",
50
- "oxfmt": "^0.35.0",
50
+ "oxfmt": "^0.55.0",
51
51
  "oxlint": "^1.50.0",
52
- "tsdown": "^0.20.3",
53
- "typescript": "5.8.2",
54
- "vitest": "4.0.15"
52
+ "tsdown": "^0.21.0",
53
+ "typescript": "5.9.3",
54
+ "vitest": "4.1.9"
55
55
  },
56
56
  "engines": {
57
57
  "node": ">=20"