@rrlab/cli 1.2.0 → 1.2.1

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,7 +1,7 @@
1
1
  // @generated by @usage-spec/commander from Commander.js metadata
2
2
  name rr
3
3
  bin rr
4
- version "1.2.0"
4
+ version "1.2.1"
5
5
  usage "[options] [command]"
6
6
  flag --about help="show credits & inspiration"
7
7
  flag --usage help="print KDL spec for this CLI (https://kdl.dev)"
package/dist/run.mjs CHANGED
@@ -371,7 +371,7 @@ function jscAction({ ctx, checker, options }) {
371
371
  }
372
372
  //#endregion
373
373
  //#region src/actions/tsc.ts
374
- const getPreScript = (scripts) => scripts?.pretsc ?? scripts?.pretypecheck;
374
+ const getPreScript = (scripts) => scripts?.pretscheck ?? scripts?.pretsc ?? scripts?.pretypecheck;
375
375
  async function tscAction({ ctx, tsc }) {
376
376
  const { appPkg, shell } = ctx;
377
377
  const isTsProject = (dir) => appPkg.hasFile("tsconfig.json", dir);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rrlab/cli",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "The CLI toolbox to fullstack common scripts in Variable Land",
5
5
  "homepage": "https://github.com/variableland/dx/tree/main/run-run/cli#readme",
6
6
  "bugs": {
@@ -70,6 +70,6 @@
70
70
  "test": "vitest run",
71
71
  "test:unit": "vitest run --project unit",
72
72
  "test:integration": "vitest run --project integration",
73
- "test:types": "rr tsc"
73
+ "tscheck": "rr tsc"
74
74
  }
75
75
  }
@@ -11,14 +11,14 @@ export type TscActionConfig = {
11
11
 
12
12
  type Scripts = Record<string, string | undefined> | undefined;
13
13
 
14
- const getPreScript = (scripts: Scripts) => scripts?.pretsc ?? scripts?.pretypecheck;
14
+ const getPreScript = (scripts: Scripts) => scripts?.pretscheck ?? scripts?.pretsc ?? scripts?.pretypecheck;
15
15
 
16
16
  export async function tscAction({ ctx, tsc }: TscActionConfig): Promise<void> {
17
17
  const { appPkg, shell } = ctx;
18
18
 
19
19
  const isTsProject = (dir: string) => appPkg.hasFile("tsconfig.json", dir);
20
20
 
21
- // A package's `pretsc`/`pretypecheck` runs captured, inside the task, so its
21
+ // A package's `pretscheck`/`pretsc`/`pretypecheck` runs captured, inside the task, so its
22
22
  // output stays grouped with that package. It may use shell features, so it
23
23
  // goes through `/bin/sh -c`. A failing pre-script fails the task before tsc.
24
24
  const typecheckTask = (label: string, dir: string, scripts: Scripts): BoardTask =>