1 | import { UnknownSnippetMode } from 'jsii-rosetta';
|
2 | import { TargetName } from './targets';
|
3 | import { Timers } from './timer';
|
4 | export { TargetName };
|
5 | export { configure as configureLogging } from './logging';
|
6 | /**
|
7 | * Generates code in the desired targets.
|
8 | */
|
9 | export declare function pacmak({ argv, clean, codeOnly, fingerprint, force, forceSubdirectory, forceTarget, inputDirectories, outputDirectory, parallel, recurse, rosettaTablet, rosettaUnknownSnippets, runtimeTypeChecking, targets, timers, updateNpmIgnoreFiles, validateAssemblies, }: PacmakOptions): Promise<void>;
|
10 | /**
|
11 | * Options provided to the `pacmak` function.
|
12 | */
|
13 | export interface PacmakOptions {
|
14 | /**
|
15 | * All command-line arguments that were provided. This includes target-specific parameters, the
|
16 | * handling of which is up to the code generators.
|
17 | *
|
18 | * @default {}
|
19 | */
|
20 | readonly argv?: {
|
21 | readonly [name: string]: any;
|
22 | };
|
23 | /**
|
24 | * Whether to clean up temporary directories upon completion.
|
25 | *
|
26 | * @default true
|
27 | */
|
28 | readonly clean?: boolean;
|
29 | /**
|
30 | * Whether to generate source code only (as opposed to built packages).
|
31 | *
|
32 | * @default false
|
33 | */
|
34 | readonly codeOnly?: boolean;
|
35 | /**
|
36 | * Whether to opportunistically include a fingerprint in generated code, to avoid re-generating
|
37 | * code if the source assembly has not changed.
|
38 | *
|
39 | * @default true
|
40 | */
|
41 | readonly fingerprint?: boolean;
|
42 | /**
|
43 | * Whether to always re-generate code, even if the fingerprint has not changed.
|
44 | *
|
45 | * @default false
|
46 | */
|
47 | readonly force?: boolean;
|
48 | /**
|
49 | * Always emit code in a per-language subdirectory, even if there is only one target language.
|
50 | *
|
51 | * @default true
|
52 | */
|
53 | readonly forceSubdirectory?: boolean;
|
54 | /**
|
55 | * Always try to generate code for the selected targets, even if those are not configured. Use this option at your own
|
56 | * risk, as there are significant chances code generators cannot operate without any configuration.
|
57 | *
|
58 | * @default false
|
59 | */
|
60 | readonly forceTarget?: boolean;
|
61 | /**
|
62 | * The list of directories to be considered for input assemblies.
|
63 | */
|
64 | readonly inputDirectories: readonly string[];
|
65 | /**
|
66 | * The directory in which to output generated packages or code (if `codeOnly` is `true`).
|
67 | *
|
68 | * @default - Configured in `package.json`
|
69 | */
|
70 | readonly outputDirectory?: string;
|
71 | /**
|
72 | * Whether to parallelize code generation. Turning this to `false` can be beneficial in certain resource-constrained
|
73 | * environments, such as free CI/CD offerings, as it reduces the pressure on IO.
|
74 | *
|
75 | * @default true
|
76 | */
|
77 | readonly parallel?: boolean;
|
78 | /**
|
79 | * Whether to recursively generate for the selected packages' dependencies.
|
80 | *
|
81 | * @default false
|
82 | */
|
83 | readonly recurse?: boolean;
|
84 | /**
|
85 | * How rosetta should treat snippets that cannot be loaded from a translation tablet.
|
86 | *
|
87 | * @default UnknownSnippetMode.VERBATIM
|
88 | */
|
89 | readonly rosettaUnknownSnippets?: UnknownSnippetMode;
|
90 | /**
|
91 | * A Rosetta tablet file where translations for code examples can be found.
|
92 | *
|
93 | * @default undefined
|
94 | */
|
95 | readonly rosettaTablet?: string;
|
96 | /**
|
97 | * Whether to inject runtime type checks in places where compile-time type checking is not performed.
|
98 | *
|
99 | * @default true
|
100 | */
|
101 | readonly runtimeTypeChecking?: boolean;
|
102 | /**
|
103 | * The list of targets for which code should be generated. Unless `forceTarget` is `true`, a given target will only
|
104 | * be generated for assemblies that have configured it.
|
105 | *
|
106 | * @default Object.values(TargetName)
|
107 | */
|
108 | readonly targets?: readonly TargetName[];
|
109 | /**
|
110 | * A `Timers` object, if you are interested in including the rosetta run in a larger set of timed operations.
|
111 | */
|
112 | readonly timers?: Timers;
|
113 | /**
|
114 | * Whether to update .npmignore files if `outputDirectory` comes from the `package.json` files.
|
115 | *
|
116 | * @default false
|
117 | */
|
118 | readonly updateNpmIgnoreFiles?: boolean;
|
119 | /**
|
120 | * Whether assemblies should be validated or not. Validation can be expensive and can be skipped if the assemblies
|
121 | * can be assumed to be valid.
|
122 | *
|
123 | * @default false
|
124 | */
|
125 | readonly validateAssemblies?: boolean;
|
126 | }
|
127 | //# sourceMappingURL=index.d.ts.map |
\ | No newline at end of file |