@goodie-ts/cli 0.1.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.
- package/dist/bin.d.ts +3 -0
- package/dist/bin.d.ts.map +1 -0
- package/dist/bin.js +14 -0
- package/dist/bin.js.map +1 -0
- package/dist/commands/generate.d.ts +22 -0
- package/dist/commands/generate.d.ts.map +1 -0
- package/dist/commands/generate.js +54 -0
- package/dist/commands/generate.js.map +1 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -0
- package/dist/run-transform.d.ts +18 -0
- package/dist/run-transform.d.ts.map +1 -0
- package/dist/run-transform.js +39 -0
- package/dist/run-transform.js.map +1 -0
- package/dist/watch.d.ts +12 -0
- package/dist/watch.d.ts.map +1 -0
- package/dist/watch.js +37 -0
- package/dist/watch.js.map +1 -0
- package/package.json +43 -0
package/dist/bin.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":""}
|
package/dist/bin.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { defineCommand, runMain } from 'citty';
|
|
3
|
+
import { generate } from './commands/generate.js';
|
|
4
|
+
const main = defineCommand({
|
|
5
|
+
meta: {
|
|
6
|
+
name: 'goodie',
|
|
7
|
+
description: 'CLI for goodie-ts compile-time dependency injection',
|
|
8
|
+
},
|
|
9
|
+
subCommands: {
|
|
10
|
+
generate,
|
|
11
|
+
},
|
|
12
|
+
});
|
|
13
|
+
runMain(main);
|
|
14
|
+
//# sourceMappingURL=bin.js.map
|
package/dist/bin.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.js","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,aAAa,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElD,MAAM,IAAI,GAAG,aAAa,CAAC;IACzB,IAAI,EAAE;QACJ,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE,qDAAqD;KACnE;IACD,WAAW,EAAE;QACX,QAAQ;KACT;CACF,CAAC,CAAC;AAEH,OAAO,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export declare const generate: import("citty").CommandDef<{
|
|
2
|
+
tsconfig: {
|
|
3
|
+
type: "string";
|
|
4
|
+
description: string;
|
|
5
|
+
default: string;
|
|
6
|
+
};
|
|
7
|
+
output: {
|
|
8
|
+
type: "string";
|
|
9
|
+
description: string;
|
|
10
|
+
default: string;
|
|
11
|
+
};
|
|
12
|
+
watch: {
|
|
13
|
+
type: "boolean";
|
|
14
|
+
description: string;
|
|
15
|
+
default: false;
|
|
16
|
+
};
|
|
17
|
+
'watch-dir': {
|
|
18
|
+
type: "string";
|
|
19
|
+
description: string;
|
|
20
|
+
};
|
|
21
|
+
}>;
|
|
22
|
+
//# sourceMappingURL=generate.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generate.d.ts","sourceRoot":"","sources":["../../src/commands/generate.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;EAoDnB,CAAC"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import path from 'node:path';
|
|
2
|
+
import { defineCommand } from 'citty';
|
|
3
|
+
import { logOutcome, runTransform } from '../run-transform.js';
|
|
4
|
+
import { watchAndRebuild } from '../watch.js';
|
|
5
|
+
export const generate = defineCommand({
|
|
6
|
+
meta: {
|
|
7
|
+
description: 'Run the goodie compile-time DI transformer',
|
|
8
|
+
},
|
|
9
|
+
args: {
|
|
10
|
+
tsconfig: {
|
|
11
|
+
type: 'string',
|
|
12
|
+
description: 'Path to tsconfig.json',
|
|
13
|
+
default: 'tsconfig.json',
|
|
14
|
+
},
|
|
15
|
+
output: {
|
|
16
|
+
type: 'string',
|
|
17
|
+
description: 'Output file path',
|
|
18
|
+
default: 'src/AppContext.generated.ts',
|
|
19
|
+
},
|
|
20
|
+
watch: {
|
|
21
|
+
type: 'boolean',
|
|
22
|
+
description: 'Watch for changes and rebuild',
|
|
23
|
+
default: false,
|
|
24
|
+
},
|
|
25
|
+
'watch-dir': {
|
|
26
|
+
type: 'string',
|
|
27
|
+
description: 'Directory to watch (default: cwd). Requires Node >= 22.13 for recursive watching.',
|
|
28
|
+
},
|
|
29
|
+
},
|
|
30
|
+
run({ args }) {
|
|
31
|
+
const cwd = process.cwd();
|
|
32
|
+
const tsConfigPath = path.resolve(cwd, args.tsconfig);
|
|
33
|
+
const outputPath = path.resolve(cwd, args.output);
|
|
34
|
+
// Always run an initial transform
|
|
35
|
+
const outcome = runTransform({ tsConfigPath, outputPath });
|
|
36
|
+
logOutcome(outcome);
|
|
37
|
+
if (!outcome.success) {
|
|
38
|
+
process.exitCode = 1;
|
|
39
|
+
return;
|
|
40
|
+
}
|
|
41
|
+
if (args.watch) {
|
|
42
|
+
const watchDir = args['watch-dir']
|
|
43
|
+
? path.resolve(cwd, args['watch-dir'])
|
|
44
|
+
: cwd;
|
|
45
|
+
console.log(`[goodie] Watching ${path.relative(cwd, watchDir) || '.'} for changes...`);
|
|
46
|
+
watchAndRebuild({
|
|
47
|
+
tsConfigPath,
|
|
48
|
+
outputPath,
|
|
49
|
+
watchDir,
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
});
|
|
54
|
+
//# sourceMappingURL=generate.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generate.js","sourceRoot":"","sources":["../../src/commands/generate.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,OAA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,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;gBACtC,CAAC,CAAC,GAAG,CAAC;YACR,OAAO,CAAC,GAAG,CAAC,qBAAqB,IAAI,CAAC,QAAQ,CAAC,GAAG,EAAE,QAAQ,CAAC,IAAI,GAAG,iBAAiB,CAAC,CAAC;YACvF,eAAe,CAAC;gBACd,YAAY;gBACZ,UAAU;gBACV,QAAQ;aACT,CAAC,CAAC;QACL,CAAC;IACH,CAAC;CACF,CAAC,CAAC"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type { RunTransformOptions, TransformFailure, TransformOutcome, TransformSuccess, } from './run-transform.js';
|
|
2
|
+
export { logOutcome, runTransform } from './run-transform.js';
|
|
3
|
+
export type { WatchHandle, WatchOptions } from './watch.js';
|
|
4
|
+
export { watchAndRebuild } from './watch.js';
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,mBAAmB,EACnB,gBAAgB,EAChB,gBAAgB,EAChB,gBAAgB,GACjB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC9D,YAAY,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAE9D,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { TransformResult } from '@goodie-ts/transformer';
|
|
2
|
+
export interface RunTransformOptions {
|
|
3
|
+
tsConfigPath: string;
|
|
4
|
+
outputPath: string;
|
|
5
|
+
}
|
|
6
|
+
export interface TransformSuccess {
|
|
7
|
+
success: true;
|
|
8
|
+
result: TransformResult;
|
|
9
|
+
durationMs: number;
|
|
10
|
+
}
|
|
11
|
+
export interface TransformFailure {
|
|
12
|
+
success: false;
|
|
13
|
+
error: Error;
|
|
14
|
+
}
|
|
15
|
+
export type TransformOutcome = TransformSuccess | TransformFailure;
|
|
16
|
+
export declare function runTransform(options: RunTransformOptions): TransformOutcome;
|
|
17
|
+
export declare function logOutcome(outcome: TransformOutcome): void;
|
|
18
|
+
//# sourceMappingURL=run-transform.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-transform.d.ts","sourceRoot":"","sources":["../src/run-transform.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAG9D,MAAM,WAAW,mBAAmB;IAClC,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,IAAI,CAAC;IACd,MAAM,EAAE,eAAe,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,KAAK,CAAC;IACf,KAAK,EAAE,KAAK,CAAC;CACd;AAED,MAAM,MAAM,gBAAgB,GAAG,gBAAgB,GAAG,gBAAgB,CAAC;AAEnE,wBAAgB,YAAY,CAAC,OAAO,EAAE,mBAAmB,GAAG,gBAAgB,CAkB3E;AAED,wBAAgB,UAAU,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI,CAgB1D"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import path from 'node:path';
|
|
2
|
+
import { TransformerError, transform } from '@goodie-ts/transformer';
|
|
3
|
+
export function runTransform(options) {
|
|
4
|
+
const start = performance.now();
|
|
5
|
+
try {
|
|
6
|
+
const result = transform({
|
|
7
|
+
tsConfigFilePath: options.tsConfigPath,
|
|
8
|
+
outputPath: options.outputPath,
|
|
9
|
+
});
|
|
10
|
+
const durationMs = performance.now() - start;
|
|
11
|
+
return { success: true, result, durationMs };
|
|
12
|
+
}
|
|
13
|
+
catch (error) {
|
|
14
|
+
if (error instanceof TransformerError) {
|
|
15
|
+
return { success: false, error };
|
|
16
|
+
}
|
|
17
|
+
return {
|
|
18
|
+
success: false,
|
|
19
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
export function logOutcome(outcome) {
|
|
24
|
+
if (outcome.success) {
|
|
25
|
+
const { result, durationMs } = outcome;
|
|
26
|
+
const ms = Math.round(durationMs);
|
|
27
|
+
console.log(`[goodie] Generated ${path.relative(process.cwd(), result.outputPath)} — ${result.beans.length} bean(s) in ${ms}ms`);
|
|
28
|
+
for (const w of result.warnings) {
|
|
29
|
+
console.warn(`[goodie] Warning: ${w}`);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
else {
|
|
33
|
+
console.error(`[goodie] Transform failed: ${outcome.error.message}`);
|
|
34
|
+
if (outcome.error instanceof TransformerError && outcome.error.hint) {
|
|
35
|
+
console.error(`[goodie] Hint: ${outcome.error.hint}`);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
//# sourceMappingURL=run-transform.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-transform.js","sourceRoot":"","sources":["../src/run-transform.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAE,gBAAgB,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAoBrE,MAAM,UAAU,YAAY,CAAC,OAA4B;IACvD,MAAM,KAAK,GAAG,WA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,CAAC,8BAA8B,OAAO,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;QACrE,IAAI,OAAO,CAAC,KAAK,YAAY,gBAAgB,IAAI,OAAO,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC;YACpE,OAAO,CAAC,KAAK,CAAC,kBAAkB,OAAO,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;QACxD,CAAC;IACH,CAAC;AACH,CAAC"}
|
package/dist/watch.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { RunTransformOptions } from './run-transform.js';
|
|
2
|
+
export interface WatchOptions extends RunTransformOptions {
|
|
3
|
+
/** Directory to watch (defaults to cwd) */
|
|
4
|
+
watchDir: string;
|
|
5
|
+
/** Debounce interval in ms (default: 100) */
|
|
6
|
+
debounceMs?: number;
|
|
7
|
+
}
|
|
8
|
+
export interface WatchHandle {
|
|
9
|
+
close(): void;
|
|
10
|
+
}
|
|
11
|
+
export declare function watchAndRebuild(options: WatchOptions): WatchHandle;
|
|
12
|
+
//# sourceMappingURL=watch.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"watch.d.ts","sourceRoot":"","sources":["../src/watch.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAK9D,MAAM,WAAW,YAAa,SAAQ,mBAAmB;IACvD,2CAA2C;IAC3C,QAAQ,EAAE,MAAM,CAAC;IACjB,6CAA6C;IAC7C,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,WAAW;IAC1B,KAAK,IAAI,IAAI,CAAC;CACf;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,YAAY,GAAG,WAAW,CAsClE"}
|
package/dist/watch.js
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import fs from 'node:fs';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { logOutcome, runTransform } from './run-transform.js';
|
|
4
|
+
const DEFAULT_DEBOUNCE_MS = 100;
|
|
5
|
+
export function watchAndRebuild(options) {
|
|
6
|
+
const debounceMs = options.debounceMs ?? DEFAULT_DEBOUNCE_MS;
|
|
7
|
+
const normalizedOutput = path.normalize(options.outputPath);
|
|
8
|
+
let debounceTimer;
|
|
9
|
+
const watcher = fs.watch(options.watchDir, { recursive: true }, (_event, filename) => {
|
|
10
|
+
if (!filename)
|
|
11
|
+
return;
|
|
12
|
+
// Only react to .ts files
|
|
13
|
+
if (!filename.endsWith('.ts'))
|
|
14
|
+
return;
|
|
15
|
+
// Skip the generated output file to prevent infinite loops
|
|
16
|
+
const absolutePath = path.resolve(options.watchDir, filename);
|
|
17
|
+
if (path.normalize(absolutePath) === normalizedOutput)
|
|
18
|
+
return;
|
|
19
|
+
if (debounceTimer !== undefined) {
|
|
20
|
+
clearTimeout(debounceTimer);
|
|
21
|
+
}
|
|
22
|
+
debounceTimer = setTimeout(() => {
|
|
23
|
+
debounceTimer = undefined;
|
|
24
|
+
const outcome = runTransform(options);
|
|
25
|
+
logOutcome(outcome);
|
|
26
|
+
}, debounceMs);
|
|
27
|
+
});
|
|
28
|
+
return {
|
|
29
|
+
close() {
|
|
30
|
+
if (debounceTimer !== undefined) {
|
|
31
|
+
clearTimeout(debounceTimer);
|
|
32
|
+
}
|
|
33
|
+
watcher.close();
|
|
34
|
+
},
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=watch.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"watch.js","sourceRoot":"","sources":["../src/watch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAE9D,MAAM,mBAAmB,GAAG,GAAG,CAAC;AAahC,MAAM,UAAU,eAAe,CAAC,OAAqB;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.1.1",
|
|
4
|
+
"description": "CLI for goodie-ts compile-time dependency injection",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "https://github.com/GOOD-Code-ApS/goodie.git",
|
|
10
|
+
"directory": "packages/cli"
|
|
11
|
+
},
|
|
12
|
+
"publishConfig": {
|
|
13
|
+
"access": "public"
|
|
14
|
+
},
|
|
15
|
+
"engines": {
|
|
16
|
+
"node": ">=22.13.0"
|
|
17
|
+
},
|
|
18
|
+
"main": "dist/index.js",
|
|
19
|
+
"types": "dist/index.d.ts",
|
|
20
|
+
"bin": {
|
|
21
|
+
"goodie": "dist/bin.js"
|
|
22
|
+
},
|
|
23
|
+
"exports": {
|
|
24
|
+
".": {
|
|
25
|
+
"types": "./dist/index.d.ts",
|
|
26
|
+
"import": "./dist/index.js"
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"scripts": {
|
|
30
|
+
"build": "tsc",
|
|
31
|
+
"clean": "rm -rf dist *.tsbuildinfo"
|
|
32
|
+
},
|
|
33
|
+
"dependencies": {
|
|
34
|
+
"@goodie-ts/transformer": "workspace:*",
|
|
35
|
+
"citty": "^0.1.6"
|
|
36
|
+
},
|
|
37
|
+
"devDependencies": {
|
|
38
|
+
"@types/node": "^22.0.0"
|
|
39
|
+
},
|
|
40
|
+
"files": [
|
|
41
|
+
"dist"
|
|
42
|
+
]
|
|
43
|
+
}
|