paratix 0.0.1 → 0.1.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.
- package/README.md +81 -3
- package/dist/chunk-DUIGEB2J.js +439 -0
- package/dist/chunk-DUIGEB2J.js.map +1 -0
- package/dist/chunk-G3BMCQKU.js +1706 -0
- package/dist/chunk-G3BMCQKU.js.map +1 -0
- package/dist/chunk-ULJMW23T.js +4961 -0
- package/dist/chunk-ULJMW23T.js.map +1 -0
- package/dist/cli.d.ts +62 -0
- package/dist/cli.js +779 -0
- package/dist/cli.js.map +1 -0
- package/dist/index.d.ts +201 -0
- package/dist/index.js +620 -0
- package/dist/index.js.map +1 -0
- package/dist/modules/index.d.ts +1332 -0
- package/dist/modules/index.js +56 -0
- package/dist/modules/index.js.map +1 -0
- package/dist/types-BPzPHfax.d.ts +252 -0
- package/llm-guide.md +607 -0
- package/package.json +35 -2
package/dist/cli.d.ts
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { E as Environment, S as ServerDefinition } from './types-BPzPHfax.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Type guard that checks whether `value` has the shape of a
|
|
5
|
+
* {@link ServerDefinition} — an object with a non-empty string `name`,
|
|
6
|
+
* a non-empty string `host`, a valid `ssh` config, and a non-empty `run` array.
|
|
7
|
+
*
|
|
8
|
+
* @param value - The value to inspect.
|
|
9
|
+
* @returns `true` when `value` satisfies the structural requirements of `ServerDefinition`.
|
|
10
|
+
*/
|
|
11
|
+
declare function isServerDefinitionLike(value: unknown): value is ServerDefinition;
|
|
12
|
+
/**
|
|
13
|
+
* Collects human-readable error messages for every property of `value` that
|
|
14
|
+
* does not conform to the `ServerDefinition` shape.
|
|
15
|
+
*
|
|
16
|
+
* @param value - The value to validate.
|
|
17
|
+
* @returns An array of error strings, empty when `value` is structurally valid.
|
|
18
|
+
*/
|
|
19
|
+
declare function collectDefinitionErrors(value: unknown): string[];
|
|
20
|
+
/**
|
|
21
|
+
* Prints a structured error message to stderr, including the cause chain and
|
|
22
|
+
* optionally the full stack trace when `verbose` is `true`.
|
|
23
|
+
*
|
|
24
|
+
* @param error - The caught value (may be any type).
|
|
25
|
+
* @param verbose - When `true`, the stack trace of `error` is printed.
|
|
26
|
+
*/
|
|
27
|
+
declare function printExceptionError(error: unknown, verbose: boolean): void;
|
|
28
|
+
/**
|
|
29
|
+
* Handles a failed attempt to load the `tsx` runtime.
|
|
30
|
+
*
|
|
31
|
+
* When the failed import is for a TypeScript file (`.ts`, `.mts`, `.cts`), a
|
|
32
|
+
* clear error message is printed to stderr and the process exits with code 2.
|
|
33
|
+
* For JavaScript files the failure is silently ignored because `tsx` is not
|
|
34
|
+
* required there.
|
|
35
|
+
*
|
|
36
|
+
* @param filePath - The resolved path of the playbook file being loaded.
|
|
37
|
+
*/
|
|
38
|
+
declare function handleTsxLoadFailure(filePath: string): void;
|
|
39
|
+
/**
|
|
40
|
+
* Returns whether the current CLI module is the direct process entrypoint.
|
|
41
|
+
*
|
|
42
|
+
* This resolves symlinks on both sides so pnpm-style executable shims and
|
|
43
|
+
* symlinked `node_modules` entries still count as direct execution.
|
|
44
|
+
*
|
|
45
|
+
* @param moduleUrl - The current module URL, usually `import.meta.url`.
|
|
46
|
+
* @param candidateEntryScript - The process entry script path, usually `process.argv[1]`.
|
|
47
|
+
* @returns `true` when both paths resolve to the same file on disk.
|
|
48
|
+
*/
|
|
49
|
+
declare function isDirectCliExecution(moduleUrl: string, candidateEntryScript?: string): boolean;
|
|
50
|
+
declare function applyCliEnvironmentOverrides(environment: Environment, options: {
|
|
51
|
+
firstRun: boolean;
|
|
52
|
+
}): Environment;
|
|
53
|
+
declare function applyCliProcessEnvironment(options: {
|
|
54
|
+
firstRun: boolean;
|
|
55
|
+
}): void;
|
|
56
|
+
declare function loadServerDefinitionFromFile(file: string, options: {
|
|
57
|
+
firstRun: boolean;
|
|
58
|
+
}): Promise<ServerDefinition>;
|
|
59
|
+
declare function parsePositiveNumber(value: string): number;
|
|
60
|
+
declare function collectEnvironment(value: string, previous: Record<string, string>): Record<string, string>;
|
|
61
|
+
|
|
62
|
+
export { applyCliEnvironmentOverrides, applyCliProcessEnvironment, collectDefinitionErrors, collectEnvironment, handleTsxLoadFailure, isDirectCliExecution, isServerDefinitionLike, loadServerDefinitionFromFile, parsePositiveNumber, printExceptionError };
|