@tahminator/pipeline 1.0.20 → 1.0.21

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,9 +1,26 @@
1
+ import { $ } from "bun";
2
+ type SonarScannerOpts = {
3
+ auth: {
4
+ token: string;
5
+ };
6
+ run: {
7
+ runTestsCmd: $.ShellPromise;
8
+ };
9
+ scan: {
10
+ hostUrl?: string;
11
+ additionalArgs?: Record<string, string | number | boolean>;
12
+ projectKey: string;
13
+ organization: string;
14
+ sourceCodeDir: string;
15
+ };
16
+ };
1
17
  /**
2
18
  * @beta WIP
3
19
  */
4
20
  export declare class SonarScannerClient {
5
21
  private readonly opts;
6
- private constructor();
22
+ constructor(opts: SonarScannerOpts);
7
23
  runTests(): Promise<void>;
8
24
  uploadTests(): Promise<void>;
9
25
  }
26
+ export {};
@@ -1,3 +1,4 @@
1
+ import { isCmdAvailable } from "./cmd";
1
2
  import { Colors } from "./colors";
2
3
  import { getEnvVariables } from "./env";
3
4
  import { Log } from "./log";
@@ -8,4 +9,5 @@ export declare class Utils {
8
9
  static getEnvVariables(...args: Parameters<typeof getEnvVariables>): Promise<Record<string, string>>;
9
10
  static generateShortId(...args: Parameters<typeof generateShortId>): string;
10
11
  static updateAllPackageJsonsWithVersion(version: string): Promise<void>;
12
+ static isCmdAvailable(...args: Parameters<typeof isCmdAvailable>): Promise<boolean>;
11
13
  }
@@ -1,4 +1,5 @@
1
1
  import { $ } from "bun";
2
+ import { isCmdAvailable } from "./cmd";
2
3
  import { Colors } from "./colors";
3
4
  import { getEnvVariables } from "./env";
4
5
  import { Log } from "./log";
@@ -25,4 +26,7 @@ export class Utils {
25
26
  console.log(`Successfully updated version in ${fileLocation} to ${version}`);
26
27
  }
27
28
  }
29
+ static async isCmdAvailable(...args) {
30
+ return isCmdAvailable(...args);
31
+ }
28
32
  }
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "type": "module",
4
4
  "author": "Tahmid Ahmed",
5
5
  "description": "A collection of Bun shell scripts that can be re-used in various CICD pipelines.",
6
- "version": "1.0.20",
6
+ "version": "1.0.21",
7
7
  "repository": {
8
8
  "url": "git+https://github.com/tahminator/pipeline.git"
9
9
  },