tsarr 1.12.0 → 2.0.0

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.
@@ -0,0 +1,12 @@
1
+ export type OutputFormat = 'json' | 'table' | 'quiet';
2
+ export declare function detectFormat(args: {
3
+ json?: boolean;
4
+ table?: boolean;
5
+ quiet?: boolean;
6
+ }): OutputFormat;
7
+ export declare function formatOutput(data: unknown, options: {
8
+ format: OutputFormat;
9
+ columns?: string[];
10
+ idField?: string;
11
+ }): void;
12
+ //# sourceMappingURL=output.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../src/cli/output.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;AAEtD,wBAAgB,YAAY,CAAC,IAAI,EAAE;IACjC,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,GAAG,YAAY,CAKf;AAED,wBAAgB,YAAY,CAC1B,IAAI,EAAE,OAAO,EACb,OAAO,EAAE;IACP,MAAM,EAAE,YAAY,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,GACA,IAAI,CAqBN"}
@@ -0,0 +1,11 @@
1
+ export declare function promptIfMissing(value: string | undefined, message: string): Promise<string>;
2
+ export declare function promptConfirm(message: string, skipPrompt?: boolean): Promise<boolean>;
3
+ export declare function promptSelect(message: string, options: {
4
+ label: string;
5
+ value: string;
6
+ }[]): Promise<string>;
7
+ export declare function promptMultiSelect(message: string, options: {
8
+ label: string;
9
+ value: string;
10
+ }[]): Promise<string[]>;
11
+ //# sourceMappingURL=prompt.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"prompt.d.ts","sourceRoot":"","sources":["../../src/cli/prompt.ts"],"names":[],"mappings":"AAEA,wBAAsB,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAUjG;AAED,wBAAsB,aAAa,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,UAAQ,GAAG,OAAO,CAAC,OAAO,CAAC,CASzF;AAED,wBAAsB,YAAY,CAChC,OAAO,EAAE,MAAM,EACf,OAAO,EAAE;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,EAAE,GAC1C,OAAO,CAAC,MAAM,CAAC,CASjB;AAED,wBAAsB,iBAAiB,CACrC,OAAO,EAAE,MAAM,EACf,OAAO,EAAE;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,EAAE,GAC1C,OAAO,CAAC,MAAM,EAAE,CAAC,CASnB"}
Binary file
package/package.json CHANGED
@@ -1,11 +1,14 @@
1
1
  {
2
2
  "name": "tsarr",
3
- "version": "1.12.0",
3
+ "version": "2.0.0",
4
4
  "author": "Robbe Verhelst",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "https://github.com/robbeverhelst/tsarr.git"
8
8
  },
9
+ "bin": {
10
+ "tsarr": "./dist/cli/index.js"
11
+ },
9
12
  "main": "dist/index.js",
10
13
  "module": "dist/index.js",
11
14
  "devDependencies": {
@@ -86,7 +89,8 @@
86
89
  "typescript",
87
90
  "sdk",
88
91
  "api",
89
- "bun"
92
+ "bun",
93
+ "cli"
90
94
  ],
91
95
  "license": "MIT",
92
96
  "publishConfig": {
@@ -94,12 +98,14 @@
94
98
  "registry": "https://registry.npmjs.org/"
95
99
  },
96
100
  "scripts": {
97
- "build": "bun run generate && bun run generate:types && bun run build:js && bun run build:types",
101
+ "build": "bun run generate && bun run generate:types && bun run build:js && bun run build:cli && bun run build:types",
98
102
  "build:js": "bun build src/index.ts --outdir dist --target node --minify --splitting && bun build src/clients/radarr.ts --outdir dist/clients --target node --format esm && bun build src/clients/sonarr.ts --outdir dist/clients --target node --format esm && bun build src/clients/lidarr.ts --outdir dist/clients --target node --format esm && bun build src/clients/readarr.ts --outdir dist/clients --target node --format esm && bun build src/clients/prowlarr.ts --outdir dist/clients --target node --format esm && bun build src/clients/bazarr.ts --outdir dist/clients --target node --format esm",
103
+ "build:cli": "bun build src/cli/index.ts --outdir dist/cli --target bun --format esm && chmod +x dist/cli/index.js",
99
104
  "build:types": "tsc --project tsconfig.build.json",
100
105
  "prepublishOnly": "bun run build",
101
106
  "test": "bun test",
102
107
  "dev": "bun run src/index.ts",
108
+ "cli": "bun run src/cli/index.ts",
103
109
  "lint": "biome check .",
104
110
  "lint:fix": "biome check . --write",
105
111
  "format": "biome format . --write",
@@ -116,5 +122,9 @@
116
122
  },
117
123
  "sideEffects": false,
118
124
  "type": "module",
119
- "types": "dist/index.d.ts"
125
+ "types": "dist/index.d.ts",
126
+ "dependencies": {
127
+ "citty": "^0.2.1",
128
+ "consola": "^3.4.2"
129
+ }
120
130
  }
Binary file