tsarr 2.4.2 → 2.4.3
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/commands/lidarr.d.ts.map +1 -1
- package/dist/cli/commands/prowlarr.d.ts.map +1 -1
- package/dist/cli/commands/radarr.d.ts +2 -0
- package/dist/cli/commands/radarr.d.ts.map +1 -1
- package/dist/cli/commands/readarr.d.ts.map +1 -1
- package/dist/cli/commands/service.d.ts +2 -0
- package/dist/cli/commands/service.d.ts.map +1 -1
- package/dist/cli/commands/sonarr.d.ts +2 -0
- package/dist/cli/commands/sonarr.d.ts.map +1 -1
- package/dist/cli/index.js +39 -5
- package/dist/tsarr-2.4.3.tgz +0 -0
- package/package.json +1 -1
- package/dist/tsarr-2.4.2.tgz +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lidarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/lidarr.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"lidarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/lidarr.ts"],"names":[],"mappings":"AA0hBA,eAAO,MAAM,MAAM,qDAKlB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prowlarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/prowlarr.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"prowlarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/prowlarr.ts"],"names":[],"mappings":"AAwTA,eAAO,MAAM,QAAQ,qDAKpB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"radarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/radarr.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"radarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/radarr.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAGhD,eAAO,MAAM,SAAS,EAAE,WAAW,EAmjBlC,CAAC;AAEF,eAAO,MAAM,MAAM,qDAKlB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"readarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/readarr.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"readarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/readarr.ts"],"names":[],"mappings":"AA2hBA,eAAO,MAAM,OAAO,qDAKnB,CAAC"}
|
|
@@ -19,5 +19,7 @@ export interface ResourceDef {
|
|
|
19
19
|
description: string;
|
|
20
20
|
actions: ActionDef[];
|
|
21
21
|
}
|
|
22
|
+
export declare const COMMAND_OUTPUT_COLUMNS: string[];
|
|
23
|
+
export declare function limitResults<T>(results: T[], limit: number | undefined): T[];
|
|
22
24
|
export declare function buildServiceCommand(serviceName: string, description: string, clientFactory: (config: ServarrClientConfig) => any, resources: ResourceDef[]): import("citty").CommandDef<import("citty").ArgsDef>;
|
|
23
25
|
//# sourceMappingURL=service.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"service.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/service.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAK/D,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAC;CACxC;AAED,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,SAAS,EAAE,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,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CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,SAAS,EAAE,CAAC;CACtB;AAED,eAAO,MAAM,sBAAsB,UAA0D,CAAC;AAE9F,wBAAgB,YAAY,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,CAAC,EAAE,CAM5E;AAED,wBAAgB,mBAAmB,CACjC,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,EACnB,aAAa,EAAE,CAAC,MAAM,EAAE,mBAAmB,KAAK,GAAG,EACnD,SAAS,EAAE,WAAW,EAAE,uDA+JzB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sonarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/sonarr.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sonarr.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/sonarr.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAGhD,eAAO,MAAM,SAAS,EAAE,WAAW,EAomBlC,CAAC;AAEF,eAAO,MAAM,MAAM,qDAKlB,CAAC"}
|
package/dist/cli/index.js
CHANGED
|
@@ -5059,6 +5059,14 @@ var init_output = __esm(() => {
|
|
|
5059
5059
|
});
|
|
5060
5060
|
|
|
5061
5061
|
// src/cli/commands/service.ts
|
|
5062
|
+
function limitResults(results, limit) {
|
|
5063
|
+
if (limit === undefined)
|
|
5064
|
+
return results;
|
|
5065
|
+
if (!Number.isInteger(limit) || limit < 1) {
|
|
5066
|
+
throw new Error("--limit must be a positive integer.");
|
|
5067
|
+
}
|
|
5068
|
+
return results.slice(0, limit);
|
|
5069
|
+
}
|
|
5062
5070
|
function buildServiceCommand(serviceName, description, clientFactory, resources) {
|
|
5063
5071
|
const subCommands = {};
|
|
5064
5072
|
for (const resource of resources) {
|
|
@@ -5245,6 +5253,7 @@ Run \`tsarr doctor\` to diagnose.`);
|
|
|
5245
5253
|
}
|
|
5246
5254
|
process.exit(1);
|
|
5247
5255
|
}
|
|
5256
|
+
var COMMAND_OUTPUT_COLUMNS;
|
|
5248
5257
|
var init_service = __esm(() => {
|
|
5249
5258
|
init_dist();
|
|
5250
5259
|
init_dist2();
|
|
@@ -5252,11 +5261,13 @@ var init_service = __esm(() => {
|
|
|
5252
5261
|
init_config();
|
|
5253
5262
|
init_output();
|
|
5254
5263
|
init_prompt2();
|
|
5264
|
+
COMMAND_OUTPUT_COLUMNS = ["id", "name", "status", "result", "queued", "trigger"];
|
|
5255
5265
|
});
|
|
5256
5266
|
|
|
5257
5267
|
// src/cli/commands/radarr.ts
|
|
5258
5268
|
var exports_radarr3 = {};
|
|
5259
5269
|
__export(exports_radarr3, {
|
|
5270
|
+
resources: () => resources,
|
|
5260
5271
|
radarr: () => radarr
|
|
5261
5272
|
});
|
|
5262
5273
|
import { readFileSync as readFileSync2 } from "node:fs";
|
|
@@ -5330,10 +5341,16 @@ var init_radarr3 = __esm(() => {
|
|
|
5330
5341
|
{
|
|
5331
5342
|
name: "search",
|
|
5332
5343
|
description: "Search for movies on TMDB",
|
|
5333
|
-
args: [
|
|
5344
|
+
args: [
|
|
5345
|
+
{ name: "term", description: "Search term", required: true },
|
|
5346
|
+
{ name: "limit", description: "Max results to show", type: "number" }
|
|
5347
|
+
],
|
|
5334
5348
|
columns: ["tmdbId", "title", "year", "overview"],
|
|
5335
5349
|
idField: "tmdbId",
|
|
5336
|
-
run: (c3, a2) =>
|
|
5350
|
+
run: async (c3, a2) => {
|
|
5351
|
+
const results = unwrapData(await c3.searchMovies(a2.term));
|
|
5352
|
+
return limitResults(results, a2.limit);
|
|
5353
|
+
}
|
|
5337
5354
|
},
|
|
5338
5355
|
{
|
|
5339
5356
|
name: "add",
|
|
@@ -5428,12 +5445,14 @@ var init_radarr3 = __esm(() => {
|
|
|
5428
5445
|
name: "refresh",
|
|
5429
5446
|
description: "Refresh movie metadata",
|
|
5430
5447
|
args: [{ name: "id", description: "Movie ID", required: true, type: "number" }],
|
|
5448
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
5431
5449
|
run: (c3, a2) => c3.runCommand({ name: "RefreshMovie", movieIds: [a2.id] })
|
|
5432
5450
|
},
|
|
5433
5451
|
{
|
|
5434
5452
|
name: "manual-search",
|
|
5435
5453
|
description: "Trigger a manual search for releases",
|
|
5436
5454
|
args: [{ name: "id", description: "Movie ID", required: true, type: "number" }],
|
|
5455
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
5437
5456
|
run: (c3, a2) => c3.runCommand({ name: "MoviesSearch", movieIds: [a2.id] })
|
|
5438
5457
|
},
|
|
5439
5458
|
{
|
|
@@ -8236,7 +8255,8 @@ var init_sonarr2 = __esm(() => {
|
|
|
8236
8255
|
// src/cli/commands/sonarr.ts
|
|
8237
8256
|
var exports_sonarr3 = {};
|
|
8238
8257
|
__export(exports_sonarr3, {
|
|
8239
|
-
sonarr: () => sonarr
|
|
8258
|
+
sonarr: () => sonarr,
|
|
8259
|
+
resources: () => resources2
|
|
8240
8260
|
});
|
|
8241
8261
|
import { readFileSync as readFileSync3 } from "node:fs";
|
|
8242
8262
|
function unwrapData2(result) {
|
|
@@ -8353,9 +8373,15 @@ var init_sonarr3 = __esm(() => {
|
|
|
8353
8373
|
{
|
|
8354
8374
|
name: "search",
|
|
8355
8375
|
description: "Search for TV series",
|
|
8356
|
-
args: [
|
|
8376
|
+
args: [
|
|
8377
|
+
{ name: "term", description: "Search term", required: true },
|
|
8378
|
+
{ name: "limit", description: "Max results to show", type: "number" }
|
|
8379
|
+
],
|
|
8357
8380
|
columns: ["tvdbId", "title", "year", "overview"],
|
|
8358
|
-
run: (c3, a2) =>
|
|
8381
|
+
run: async (c3, a2) => {
|
|
8382
|
+
const results = unwrapData2(await c3.searchSeries(a2.term));
|
|
8383
|
+
return limitResults(results, a2.limit);
|
|
8384
|
+
}
|
|
8359
8385
|
},
|
|
8360
8386
|
{
|
|
8361
8387
|
name: "add",
|
|
@@ -8447,12 +8473,14 @@ var init_sonarr3 = __esm(() => {
|
|
|
8447
8473
|
name: "refresh",
|
|
8448
8474
|
description: "Refresh series metadata",
|
|
8449
8475
|
args: [{ name: "id", description: "Series ID", required: true, type: "number" }],
|
|
8476
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
8450
8477
|
run: (c3, a2) => c3.runCommand({ name: "RefreshSeries", seriesId: a2.id })
|
|
8451
8478
|
},
|
|
8452
8479
|
{
|
|
8453
8480
|
name: "manual-search",
|
|
8454
8481
|
description: "Trigger a manual search for releases",
|
|
8455
8482
|
args: [{ name: "id", description: "Series ID", required: true, type: "number" }],
|
|
8483
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
8456
8484
|
run: (c3, a2) => c3.runCommand({ name: "SeriesSearch", seriesId: a2.id })
|
|
8457
8485
|
},
|
|
8458
8486
|
{
|
|
@@ -8505,6 +8533,7 @@ var init_sonarr3 = __esm(() => {
|
|
|
8505
8533
|
name: "search",
|
|
8506
8534
|
description: "Trigger a search for an episode",
|
|
8507
8535
|
args: [{ name: "id", description: "Episode ID", required: true, type: "number" }],
|
|
8536
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
8508
8537
|
run: (c3, a2) => c3.runCommand({ name: "EpisodeSearch", episodeIds: [a2.id] })
|
|
8509
8538
|
}
|
|
8510
8539
|
]
|
|
@@ -11396,12 +11425,14 @@ var init_lidarr3 = __esm(() => {
|
|
|
11396
11425
|
name: "refresh",
|
|
11397
11426
|
description: "Refresh artist metadata",
|
|
11398
11427
|
args: [{ name: "id", description: "Artist ID", required: true, type: "number" }],
|
|
11428
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
11399
11429
|
run: (c3, a2) => c3.runCommand({ name: "RefreshArtist", artistId: a2.id })
|
|
11400
11430
|
},
|
|
11401
11431
|
{
|
|
11402
11432
|
name: "manual-search",
|
|
11403
11433
|
description: "Trigger a manual search for releases",
|
|
11404
11434
|
args: [{ name: "id", description: "Artist ID", required: true, type: "number" }],
|
|
11435
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
11405
11436
|
run: (c3, a2) => c3.runCommand({ name: "ArtistSearch", artistId: a2.id })
|
|
11406
11437
|
},
|
|
11407
11438
|
{
|
|
@@ -14316,12 +14347,14 @@ var init_readarr3 = __esm(() => {
|
|
|
14316
14347
|
name: "refresh",
|
|
14317
14348
|
description: "Refresh author metadata",
|
|
14318
14349
|
args: [{ name: "id", description: "Author ID", required: true, type: "number" }],
|
|
14350
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
14319
14351
|
run: (c3, a2) => c3.runCommand({ name: "RefreshAuthor", authorId: a2.id })
|
|
14320
14352
|
},
|
|
14321
14353
|
{
|
|
14322
14354
|
name: "manual-search",
|
|
14323
14355
|
description: "Trigger a manual search for releases",
|
|
14324
14356
|
args: [{ name: "id", description: "Author ID", required: true, type: "number" }],
|
|
14357
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
14325
14358
|
run: (c3, a2) => c3.runCommand({ name: "AuthorSearch", authorId: a2.id })
|
|
14326
14359
|
},
|
|
14327
14360
|
{
|
|
@@ -16537,6 +16570,7 @@ var init_prowlarr3 = __esm(() => {
|
|
|
16537
16570
|
{
|
|
16538
16571
|
name: "sync",
|
|
16539
16572
|
description: "Trigger app indexer sync",
|
|
16573
|
+
columns: COMMAND_OUTPUT_COLUMNS,
|
|
16540
16574
|
run: (c3) => c3.runCommand({ name: "AppIndexerMapSync" })
|
|
16541
16575
|
}
|
|
16542
16576
|
]
|
|
Binary file
|
package/package.json
CHANGED
package/dist/tsarr-2.4.2.tgz
DELETED
|
Binary file
|