@eserstack/codebase 0.0.0-stage → 5.0.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 +301 -2
- package/dist/changelog-gen.d.ts +105 -0
- package/dist/changelog-gen.js +498 -0
- package/dist/changelog-text.d.ts +39 -0
- package/dist/changelog-text.js +82 -0
- package/dist/cli-support.d.ts +140 -0
- package/dist/cli-support.js +244 -0
- package/dist/cli-system/app-opts.d.ts +15 -0
- package/dist/cli-system/app-opts.js +13 -0
- package/dist/cli-system/app.d.ts +29 -0
- package/dist/cli-system/app.js +12 -0
- package/dist/cli-system/handlers/completions-setup.d.ts +14 -0
- package/dist/cli-system/handlers/completions-setup.js +139 -0
- package/dist/cli-system/handlers/completions.d.ts +3 -0
- package/dist/cli-system/handlers/completions.js +79 -0
- package/dist/cli-system/handlers/doctor.d.ts +8 -0
- package/dist/cli-system/handlers/doctor.js +146 -0
- package/dist/cli-system/handlers/info.d.ts +3 -0
- package/dist/cli-system/handlers/info.js +69 -0
- package/dist/cli-system/handlers/install.d.ts +8 -0
- package/dist/cli-system/handlers/install.js +137 -0
- package/dist/cli-system/handlers/mod.d.ts +12 -0
- package/dist/cli-system/handlers/mod.js +13 -0
- package/dist/cli-system/handlers/uninstall.d.ts +3 -0
- package/dist/cli-system/handlers/uninstall.js +60 -0
- package/dist/cli-system/handlers/update.d.ts +76 -0
- package/dist/cli-system/handlers/update.js +310 -0
- package/dist/cli-system/handlers/version-check.d.ts +16 -0
- package/dist/cli-system/handlers/version-check.js +176 -0
- package/dist/cli-system/handlers/version.d.ts +3 -0
- package/dist/cli-system/handlers/version.js +45 -0
- package/dist/cli-system/mod.d.ts +19 -0
- package/dist/cli-system/mod.js +52 -0
- package/dist/commitmsg.d.ts +28 -0
- package/dist/commitmsg.js +232 -0
- package/dist/directive-analysis.d.ts +75 -0
- package/dist/directive-analysis.js +223 -0
- package/dist/ffi-client.d.ts +11 -0
- package/dist/ffi-client.js +12 -0
- package/dist/file-tool.d.ts +96 -0
- package/dist/file-tool.js +274 -0
- package/dist/file-tools-shared.d.ts +81 -0
- package/dist/file-tools-shared.js +276 -0
- package/dist/gh-contributors.d.ts +89 -0
- package/dist/gh-contributors.js +205 -0
- package/dist/gh.d.ts +3 -0
- package/dist/gh.js +64 -0
- package/dist/git-listing.d.ts +27 -0
- package/dist/git-listing.js +69 -0
- package/dist/git.d.ts +172 -0
- package/dist/git.js +277 -0
- package/dist/install.d.ts +34 -0
- package/dist/install.js +421 -0
- package/dist/main.d.ts +22 -0
- package/dist/main.js +14 -0
- package/dist/mod.d.ts +25 -0
- package/dist/mod.js +8 -0
- package/dist/module.d.ts +10 -0
- package/dist/module.js +221 -0
- package/dist/native-functions.d.ts +1088 -0
- package/dist/native-functions.js +2 -0
- package/dist/npm-externals.d.ts +27 -0
- package/dist/npm-externals.js +34 -0
- package/dist/npm-workspace-specifiers.d.ts +6 -0
- package/dist/npm-workspace-specifiers.js +45 -0
- package/dist/package/loader.d.ts +34 -0
- package/dist/package/loader.js +203 -0
- package/dist/package/mod.d.ts +36 -0
- package/dist/package/mod.js +5 -0
- package/dist/package/types.d.ts +142 -0
- package/dist/package/types.js +32 -0
- package/dist/package/workspace.d.ts +33 -0
- package/dist/package/workspace.js +158 -0
- package/dist/package/writer.d.ts +52 -0
- package/dist/package/writer.js +278 -0
- package/dist/package.json +275 -0
- package/dist/release-notes.d.ts +90 -0
- package/dist/release-notes.js +236 -0
- package/dist/release-tag.d.ts +46 -0
- package/dist/release-tag.js +95 -0
- package/dist/release.d.ts +145 -0
- package/dist/release.js +584 -0
- package/dist/source-mask.d.ts +3 -0
- package/dist/source-mask.js +185 -0
- package/dist/validate-bom.d.ts +5 -0
- package/dist/validate-bom.js +43 -0
- package/dist/validate-case-conflict.d.ts +5 -0
- package/dist/validate-case-conflict.js +43 -0
- package/dist/validate-circular-deps.d.ts +11 -0
- package/dist/validate-circular-deps.js +53 -0
- package/dist/validate-code-conventions.d.ts +22 -0
- package/dist/validate-code-conventions.js +166 -0
- package/dist/validate-commit-msg.d.ts +50 -0
- package/dist/validate-commit-msg.js +182 -0
- package/dist/validate-docs.d.ts +20 -0
- package/dist/validate-docs.js +78 -0
- package/dist/validate-eof.d.ts +5 -0
- package/dist/validate-eof.js +61 -0
- package/dist/validate-error-coverage.d.ts +28 -0
- package/dist/validate-error-coverage.js +93 -0
- package/dist/validate-export-names.d.ts +17 -0
- package/dist/validate-export-names.js +56 -0
- package/dist/validate-filenames.d.ts +5 -0
- package/dist/validate-filenames.js +151 -0
- package/dist/validate-json.d.ts +5 -0
- package/dist/validate-json.js +71 -0
- package/dist/validate-large-files.d.ts +5 -0
- package/dist/validate-large-files.js +41 -0
- package/dist/validate-laroux-boundaries.d.ts +19 -0
- package/dist/validate-laroux-boundaries.js +59 -0
- package/dist/validate-licenses.d.ts +5 -0
- package/dist/validate-licenses.js +137 -0
- package/dist/validate-line-endings.d.ts +5 -0
- package/dist/validate-line-endings.js +47 -0
- package/dist/validate-merge-conflict.d.ts +5 -0
- package/dist/validate-merge-conflict.js +46 -0
- package/dist/validate-mod-exports.d.ts +16 -0
- package/dist/validate-mod-exports.js +56 -0
- package/dist/validate-naming-and-todos.d.ts +5 -0
- package/dist/validate-naming-and-todos.js +70 -0
- package/dist/validate-runtime-js-apis.d.ts +5 -0
- package/dist/validate-runtime-js-apis.js +78 -0
- package/dist/validate-secrets.d.ts +5 -0
- package/dist/validate-secrets.js +82 -0
- package/dist/validate-self-imports.d.ts +5 -0
- package/dist/validate-self-imports.js +78 -0
- package/dist/validate-server-loc.d.ts +32 -0
- package/dist/validate-server-loc.js +94 -0
- package/dist/validate-shebangs.d.ts +5 -0
- package/dist/validate-shebangs.js +33 -0
- package/dist/validate-stream.d.ts +25 -0
- package/dist/validate-stream.js +62 -0
- package/dist/validate-submodules.d.ts +5 -0
- package/dist/validate-submodules.js +43 -0
- package/dist/validate-symlinks.d.ts +5 -0
- package/dist/validate-symlinks.js +46 -0
- package/dist/validate-toml.d.ts +5 -0
- package/dist/validate-toml.js +40 -0
- package/dist/validate-trailing-whitespace.d.ts +5 -0
- package/dist/validate-trailing-whitespace.js +49 -0
- package/dist/validate-yaml.d.ts +5 -0
- package/dist/validate-yaml.js +40 -0
- package/dist/validation/config.d.ts +17 -0
- package/dist/validation/config.js +30 -0
- package/dist/validation/mod.d.ts +71 -0
- package/dist/validation/mod.js +479 -0
- package/dist/validation/registry.d.ts +57 -0
- package/dist/validation/registry.js +256 -0
- package/dist/validation/types.d.ts +101 -0
- package/dist/validation/types.js +2 -0
- package/dist/validation/validators/circular-deps.d.ts +7 -0
- package/dist/validation/validators/circular-deps.js +31 -0
- package/dist/validation/validators/docs.d.ts +7 -0
- package/dist/validation/validators/docs.js +38 -0
- package/dist/validation/validators/error-coverage.d.ts +2 -0
- package/dist/validation/validators/error-coverage.js +46 -0
- package/dist/validation/validators/export-names.d.ts +7 -0
- package/dist/validation/validators/export-names.js +31 -0
- package/dist/validation/validators/laroux-boundaries.d.ts +2 -0
- package/dist/validation/validators/laroux-boundaries.js +29 -0
- package/dist/validation/validators/mod-exports.d.ts +7 -0
- package/dist/validation/validators/mod-exports.js +32 -0
- package/dist/validation/validators/mod.d.ts +11 -0
- package/dist/validation/validators/mod.js +12 -0
- package/dist/validation/validators/server-loc.d.ts +2 -0
- package/dist/validation/validators/server-loc.js +48 -0
- package/dist/versions.d.ts +166 -0
- package/dist/versions.js +349 -0
- package/dist/violation-baseline.d.ts +58 -0
- package/dist/violation-baseline.js +144 -0
- package/dist/walk-stream.d.ts +24 -0
- package/dist/walk-stream.js +55 -0
- package/dist/workspace-discovery.d.ts +60 -0
- package/dist/workspace-discovery.js +130 -0
- package/package.json +222 -3
|
@@ -0,0 +1,1088 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The input and output types of the native functions this package owns, for
|
|
3
|
+
* `fromNative` of `@eserstack/functions/native`.
|
|
4
|
+
*
|
|
5
|
+
* @module
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Input of the native function `codebase-bom`.
|
|
9
|
+
*
|
|
10
|
+
* detect UTF-8 BOM
|
|
11
|
+
*/
|
|
12
|
+
export type CodebaseBomInput = {
|
|
13
|
+
readonly _changedFiles?: readonly string[];
|
|
14
|
+
readonly cwd?: string;
|
|
15
|
+
readonly dryRun?: boolean;
|
|
16
|
+
readonly exclude?: readonly string[];
|
|
17
|
+
readonly extensions?: readonly string[];
|
|
18
|
+
readonly fix?: boolean;
|
|
19
|
+
readonly root?: string;
|
|
20
|
+
readonly [key: string]: unknown;
|
|
21
|
+
};
|
|
22
|
+
/** Output of the native function `codebase-bom`. */
|
|
23
|
+
export type CodebaseBomOutput = {
|
|
24
|
+
readonly issues?: ReadonlyArray<{
|
|
25
|
+
readonly fixed?: boolean;
|
|
26
|
+
readonly line?: number;
|
|
27
|
+
readonly message: string;
|
|
28
|
+
readonly path?: string;
|
|
29
|
+
}>;
|
|
30
|
+
readonly mutations?: ReadonlyArray<{
|
|
31
|
+
readonly newContent: string;
|
|
32
|
+
readonly oldContent: string;
|
|
33
|
+
readonly path: string;
|
|
34
|
+
}>;
|
|
35
|
+
readonly passed: boolean;
|
|
36
|
+
readonly stats?: Readonly<Record<string, unknown>>;
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* Input of the native function `codebase-case-conflict`.
|
|
40
|
+
*
|
|
41
|
+
* detect case-insensitive path conflicts
|
|
42
|
+
*/
|
|
43
|
+
export type CodebaseCaseConflictInput = {
|
|
44
|
+
readonly _changedFiles?: readonly string[];
|
|
45
|
+
readonly cwd?: string;
|
|
46
|
+
readonly dryRun?: boolean;
|
|
47
|
+
readonly exclude?: readonly string[];
|
|
48
|
+
readonly extensions?: readonly string[];
|
|
49
|
+
readonly fix?: boolean;
|
|
50
|
+
readonly root?: string;
|
|
51
|
+
readonly [key: string]: unknown;
|
|
52
|
+
};
|
|
53
|
+
/** Output of the native function `codebase-case-conflict`. */
|
|
54
|
+
export type CodebaseCaseConflictOutput = CodebaseBomOutput;
|
|
55
|
+
/**
|
|
56
|
+
* Input of the native function `codebase-code-conventions`.
|
|
57
|
+
*
|
|
58
|
+
* detect non-namespace imports, `||` defaults and `export *` beyond the recorded baseline
|
|
59
|
+
*/
|
|
60
|
+
export type CodebaseCodeConventionsInput = {
|
|
61
|
+
readonly _changedFiles?: readonly string[];
|
|
62
|
+
readonly baseline?: string;
|
|
63
|
+
readonly cwd?: string;
|
|
64
|
+
readonly dryRun?: boolean;
|
|
65
|
+
readonly exclude?: readonly string[];
|
|
66
|
+
readonly extensions?: readonly string[];
|
|
67
|
+
readonly fix?: boolean;
|
|
68
|
+
readonly root?: string;
|
|
69
|
+
readonly [key: string]: unknown;
|
|
70
|
+
};
|
|
71
|
+
/** Output of the native function `codebase-code-conventions`. */
|
|
72
|
+
export type CodebaseCodeConventionsOutput = CodebaseBomOutput;
|
|
73
|
+
/**
|
|
74
|
+
* Input of the native function `codebase-eof`.
|
|
75
|
+
*
|
|
76
|
+
* check files end with exactly one newline
|
|
77
|
+
*/
|
|
78
|
+
export type CodebaseEofInput = {
|
|
79
|
+
readonly _changedFiles?: readonly string[];
|
|
80
|
+
readonly cwd?: string;
|
|
81
|
+
readonly dryRun?: boolean;
|
|
82
|
+
readonly exclude?: readonly string[];
|
|
83
|
+
readonly extensions?: readonly string[];
|
|
84
|
+
readonly fix?: boolean;
|
|
85
|
+
readonly root?: string;
|
|
86
|
+
readonly [key: string]: unknown;
|
|
87
|
+
};
|
|
88
|
+
/** Output of the native function `codebase-eof`. */
|
|
89
|
+
export type CodebaseEofOutput = CodebaseBomOutput;
|
|
90
|
+
/**
|
|
91
|
+
* Input of the native function `codebase-error-coverage`.
|
|
92
|
+
*
|
|
93
|
+
* verify error-struct entries have non-empty required fields
|
|
94
|
+
*/
|
|
95
|
+
export type CodebaseErrorCoverageInput = {
|
|
96
|
+
readonly _changedFiles?: readonly string[];
|
|
97
|
+
readonly cwd?: string;
|
|
98
|
+
readonly dryRun?: boolean;
|
|
99
|
+
readonly errorObjects?: readonly string[];
|
|
100
|
+
readonly exclude?: readonly string[];
|
|
101
|
+
readonly extensions?: readonly string[];
|
|
102
|
+
readonly file: string;
|
|
103
|
+
readonly fix?: boolean;
|
|
104
|
+
readonly requiredFields?: readonly string[];
|
|
105
|
+
readonly root?: string;
|
|
106
|
+
readonly [key: string]: unknown;
|
|
107
|
+
};
|
|
108
|
+
/** Output of the native function `codebase-error-coverage`. */
|
|
109
|
+
export type CodebaseErrorCoverageOutput = CodebaseBomOutput;
|
|
110
|
+
/**
|
|
111
|
+
* Input of the native function `codebase-filenames`.
|
|
112
|
+
*
|
|
113
|
+
* enforce filename conventions
|
|
114
|
+
*/
|
|
115
|
+
export type CodebaseFilenamesInput = {
|
|
116
|
+
readonly _changedFiles?: readonly string[];
|
|
117
|
+
readonly cwd?: string;
|
|
118
|
+
readonly dryRun?: boolean;
|
|
119
|
+
readonly exclude?: readonly string[];
|
|
120
|
+
readonly extensions?: readonly string[];
|
|
121
|
+
readonly fix?: boolean;
|
|
122
|
+
readonly globalExcludes?: readonly string[];
|
|
123
|
+
readonly root?: string;
|
|
124
|
+
readonly rules?: ReadonlyArray<{
|
|
125
|
+
readonly convention: "kebab-case" | "snake_case";
|
|
126
|
+
readonly directory: string;
|
|
127
|
+
readonly exclude?: readonly string[];
|
|
128
|
+
readonly [key: string]: unknown;
|
|
129
|
+
}> | string;
|
|
130
|
+
readonly [key: string]: unknown;
|
|
131
|
+
};
|
|
132
|
+
/** Output of the native function `codebase-filenames`. */
|
|
133
|
+
export type CodebaseFilenamesOutput = CodebaseBomOutput;
|
|
134
|
+
/**
|
|
135
|
+
* Input of the native function `codebase-json`.
|
|
136
|
+
*
|
|
137
|
+
* validate JSON and JSONC syntax
|
|
138
|
+
*/
|
|
139
|
+
export type CodebaseJsonInput = {
|
|
140
|
+
readonly _changedFiles?: readonly string[];
|
|
141
|
+
readonly cwd?: string;
|
|
142
|
+
readonly dryRun?: boolean;
|
|
143
|
+
readonly exclude?: readonly string[];
|
|
144
|
+
readonly extensions?: readonly string[];
|
|
145
|
+
readonly fix?: boolean;
|
|
146
|
+
readonly root?: string;
|
|
147
|
+
readonly [key: string]: unknown;
|
|
148
|
+
};
|
|
149
|
+
/** Output of the native function `codebase-json`. */
|
|
150
|
+
export type CodebaseJsonOutput = CodebaseBomOutput;
|
|
151
|
+
/**
|
|
152
|
+
* Input of the native function `codebase-large-file`.
|
|
153
|
+
*
|
|
154
|
+
* report files exceeding a size limit
|
|
155
|
+
*/
|
|
156
|
+
export type CodebaseLargeFileInput = {
|
|
157
|
+
readonly _changedFiles?: readonly string[];
|
|
158
|
+
readonly cwd?: string;
|
|
159
|
+
readonly dryRun?: boolean;
|
|
160
|
+
readonly exclude?: readonly string[];
|
|
161
|
+
readonly extensions?: readonly string[];
|
|
162
|
+
readonly fix?: boolean;
|
|
163
|
+
readonly maxKb?: number;
|
|
164
|
+
readonly root?: string;
|
|
165
|
+
readonly [key: string]: unknown;
|
|
166
|
+
};
|
|
167
|
+
/** Output of the native function `codebase-large-file`. */
|
|
168
|
+
export type CodebaseLargeFileOutput = CodebaseBomOutput;
|
|
169
|
+
/**
|
|
170
|
+
* Input of the native function `codebase-license`.
|
|
171
|
+
*
|
|
172
|
+
* check copyright license header in JS/TS files
|
|
173
|
+
*/
|
|
174
|
+
export type CodebaseLicenseInput = {
|
|
175
|
+
readonly _changedFiles?: readonly string[];
|
|
176
|
+
readonly cwd?: string;
|
|
177
|
+
readonly dryRun?: boolean;
|
|
178
|
+
readonly exclude?: readonly string[];
|
|
179
|
+
readonly extensions?: readonly string[];
|
|
180
|
+
readonly fix?: boolean;
|
|
181
|
+
readonly root?: string;
|
|
182
|
+
readonly [key: string]: unknown;
|
|
183
|
+
};
|
|
184
|
+
/** Output of the native function `codebase-license`. */
|
|
185
|
+
export type CodebaseLicenseOutput = CodebaseBomOutput;
|
|
186
|
+
/**
|
|
187
|
+
* Input of the native function `codebase-line-endings`.
|
|
188
|
+
*
|
|
189
|
+
* detect mixed CRLF/LF line endings
|
|
190
|
+
*/
|
|
191
|
+
export type CodebaseLineEndingsInput = {
|
|
192
|
+
readonly _changedFiles?: readonly string[];
|
|
193
|
+
readonly cwd?: string;
|
|
194
|
+
readonly dryRun?: boolean;
|
|
195
|
+
readonly exclude?: readonly string[];
|
|
196
|
+
readonly extensions?: readonly string[];
|
|
197
|
+
readonly fix?: boolean;
|
|
198
|
+
readonly root?: string;
|
|
199
|
+
readonly [key: string]: unknown;
|
|
200
|
+
};
|
|
201
|
+
/** Output of the native function `codebase-line-endings`. */
|
|
202
|
+
export type CodebaseLineEndingsOutput = CodebaseBomOutput;
|
|
203
|
+
/**
|
|
204
|
+
* Input of the native function `codebase-merge-conflicts`.
|
|
205
|
+
*
|
|
206
|
+
* detect leftover merge conflict markers
|
|
207
|
+
*/
|
|
208
|
+
export type CodebaseMergeConflictsInput = {
|
|
209
|
+
readonly _changedFiles?: readonly string[];
|
|
210
|
+
readonly cwd?: string;
|
|
211
|
+
readonly dryRun?: boolean;
|
|
212
|
+
readonly exclude?: readonly string[];
|
|
213
|
+
readonly extensions?: readonly string[];
|
|
214
|
+
readonly fix?: boolean;
|
|
215
|
+
readonly root?: string;
|
|
216
|
+
readonly [key: string]: unknown;
|
|
217
|
+
};
|
|
218
|
+
/** Output of the native function `codebase-merge-conflicts`. */
|
|
219
|
+
export type CodebaseMergeConflictsOutput = CodebaseBomOutput;
|
|
220
|
+
/**
|
|
221
|
+
* Input of the native function `codebase-naming-and-todos`.
|
|
222
|
+
*
|
|
223
|
+
* enforce camelCase names and task-tagged TODO comments in JS/TS files
|
|
224
|
+
*/
|
|
225
|
+
export type CodebaseNamingAndTodosInput = {
|
|
226
|
+
readonly _changedFiles?: readonly string[];
|
|
227
|
+
readonly allowNames?: readonly string[];
|
|
228
|
+
readonly cwd?: string;
|
|
229
|
+
readonly dryRun?: boolean;
|
|
230
|
+
readonly exclude?: readonly string[];
|
|
231
|
+
readonly extensions?: readonly string[];
|
|
232
|
+
readonly fix?: boolean;
|
|
233
|
+
readonly root?: string;
|
|
234
|
+
readonly [key: string]: unknown;
|
|
235
|
+
};
|
|
236
|
+
/** Output of the native function `codebase-naming-and-todos`. */
|
|
237
|
+
export type CodebaseNamingAndTodosOutput = CodebaseBomOutput;
|
|
238
|
+
/**
|
|
239
|
+
* Input of the native function `codebase-runtime-js-apis`.
|
|
240
|
+
*
|
|
241
|
+
* detect runtime globals used instead of @eserstack/standards/cross-runtime in JS/TS files
|
|
242
|
+
*/
|
|
243
|
+
export type CodebaseRuntimeJsApisInput = {
|
|
244
|
+
readonly _changedFiles?: readonly string[];
|
|
245
|
+
readonly cwd?: string;
|
|
246
|
+
readonly dryRun?: boolean;
|
|
247
|
+
readonly exclude?: readonly string[];
|
|
248
|
+
readonly extensions?: readonly string[];
|
|
249
|
+
readonly fix?: boolean;
|
|
250
|
+
readonly root?: string;
|
|
251
|
+
readonly [key: string]: unknown;
|
|
252
|
+
};
|
|
253
|
+
/** Output of the native function `codebase-runtime-js-apis`. */
|
|
254
|
+
export type CodebaseRuntimeJsApisOutput = CodebaseBomOutput;
|
|
255
|
+
/**
|
|
256
|
+
* Input of the native function `codebase-secrets`.
|
|
257
|
+
*
|
|
258
|
+
* detect potential secret leaks
|
|
259
|
+
*/
|
|
260
|
+
export type CodebaseSecretsInput = {
|
|
261
|
+
readonly _changedFiles?: readonly string[];
|
|
262
|
+
readonly cwd?: string;
|
|
263
|
+
readonly dryRun?: boolean;
|
|
264
|
+
readonly exclude?: readonly string[];
|
|
265
|
+
readonly extensions?: readonly string[];
|
|
266
|
+
readonly fix?: boolean;
|
|
267
|
+
readonly root?: string;
|
|
268
|
+
readonly [key: string]: unknown;
|
|
269
|
+
};
|
|
270
|
+
/** Output of the native function `codebase-secrets`. */
|
|
271
|
+
export type CodebaseSecretsOutput = CodebaseBomOutput;
|
|
272
|
+
/**
|
|
273
|
+
* Input of the native function `codebase-self-imports`.
|
|
274
|
+
*
|
|
275
|
+
* detect a package importing itself by its published name
|
|
276
|
+
*/
|
|
277
|
+
export type CodebaseSelfImportsInput = {
|
|
278
|
+
readonly _changedFiles?: readonly string[];
|
|
279
|
+
readonly cwd?: string;
|
|
280
|
+
readonly dryRun?: boolean;
|
|
281
|
+
readonly exclude?: readonly string[];
|
|
282
|
+
readonly extensions?: readonly string[];
|
|
283
|
+
readonly fix?: boolean;
|
|
284
|
+
readonly root?: string;
|
|
285
|
+
readonly [key: string]: unknown;
|
|
286
|
+
};
|
|
287
|
+
/** Output of the native function `codebase-self-imports`. */
|
|
288
|
+
export type CodebaseSelfImportsOutput = CodebaseBomOutput;
|
|
289
|
+
/**
|
|
290
|
+
* Input of the native function `codebase-server-loc`.
|
|
291
|
+
*
|
|
292
|
+
* fail if any non-test file in a directory exceeds the line ceiling
|
|
293
|
+
*/
|
|
294
|
+
export type CodebaseServerLocInput = {
|
|
295
|
+
readonly _changedFiles?: readonly string[];
|
|
296
|
+
readonly cwd?: string;
|
|
297
|
+
readonly directory: string;
|
|
298
|
+
readonly dryRun?: boolean;
|
|
299
|
+
readonly exclude?: readonly string[];
|
|
300
|
+
readonly excludeSuffix?: string;
|
|
301
|
+
readonly extension?: string;
|
|
302
|
+
readonly extensions?: readonly string[];
|
|
303
|
+
readonly fix?: boolean;
|
|
304
|
+
readonly maxLines?: number;
|
|
305
|
+
readonly root?: string;
|
|
306
|
+
readonly [key: string]: unknown;
|
|
307
|
+
};
|
|
308
|
+
/** Output of the native function `codebase-server-loc`. */
|
|
309
|
+
export type CodebaseServerLocOutput = CodebaseBomOutput;
|
|
310
|
+
/**
|
|
311
|
+
* Input of the native function `codebase-shebangs`.
|
|
312
|
+
*
|
|
313
|
+
* validate shebang lines (no-op placeholder)
|
|
314
|
+
*/
|
|
315
|
+
export type CodebaseShebangsInput = {
|
|
316
|
+
readonly _changedFiles?: readonly string[];
|
|
317
|
+
readonly cwd?: string;
|
|
318
|
+
readonly dryRun?: boolean;
|
|
319
|
+
readonly exclude?: readonly string[];
|
|
320
|
+
readonly extensions?: readonly string[];
|
|
321
|
+
readonly fix?: boolean;
|
|
322
|
+
readonly root?: string;
|
|
323
|
+
readonly [key: string]: unknown;
|
|
324
|
+
};
|
|
325
|
+
/** Output of the native function `codebase-shebangs`. */
|
|
326
|
+
export type CodebaseShebangsOutput = CodebaseBomOutput;
|
|
327
|
+
/**
|
|
328
|
+
* Input of the native function `codebase-submodules`.
|
|
329
|
+
*
|
|
330
|
+
* detect git submodule references
|
|
331
|
+
*/
|
|
332
|
+
export type CodebaseSubmodulesInput = {
|
|
333
|
+
readonly _changedFiles?: readonly string[];
|
|
334
|
+
readonly cwd?: string;
|
|
335
|
+
readonly dryRun?: boolean;
|
|
336
|
+
readonly exclude?: readonly string[];
|
|
337
|
+
readonly extensions?: readonly string[];
|
|
338
|
+
readonly fix?: boolean;
|
|
339
|
+
readonly root?: string;
|
|
340
|
+
readonly [key: string]: unknown;
|
|
341
|
+
};
|
|
342
|
+
/** Output of the native function `codebase-submodules`. */
|
|
343
|
+
export type CodebaseSubmodulesOutput = CodebaseBomOutput;
|
|
344
|
+
/**
|
|
345
|
+
* Input of the native function `codebase-symlinks`.
|
|
346
|
+
*
|
|
347
|
+
* detect broken symbolic links
|
|
348
|
+
*/
|
|
349
|
+
export type CodebaseSymlinksInput = {
|
|
350
|
+
readonly _changedFiles?: readonly string[];
|
|
351
|
+
readonly cwd?: string;
|
|
352
|
+
readonly dryRun?: boolean;
|
|
353
|
+
readonly exclude?: readonly string[];
|
|
354
|
+
readonly extensions?: readonly string[];
|
|
355
|
+
readonly fix?: boolean;
|
|
356
|
+
readonly root?: string;
|
|
357
|
+
readonly [key: string]: unknown;
|
|
358
|
+
};
|
|
359
|
+
/** Output of the native function `codebase-symlinks`. */
|
|
360
|
+
export type CodebaseSymlinksOutput = CodebaseBomOutput;
|
|
361
|
+
/**
|
|
362
|
+
* Input of the native function `codebase-toml`.
|
|
363
|
+
*
|
|
364
|
+
* validate TOML syntax
|
|
365
|
+
*/
|
|
366
|
+
export type CodebaseTomlInput = {
|
|
367
|
+
readonly _changedFiles?: readonly string[];
|
|
368
|
+
readonly cwd?: string;
|
|
369
|
+
readonly dryRun?: boolean;
|
|
370
|
+
readonly exclude?: readonly string[];
|
|
371
|
+
readonly extensions?: readonly string[];
|
|
372
|
+
readonly fix?: boolean;
|
|
373
|
+
readonly root?: string;
|
|
374
|
+
readonly [key: string]: unknown;
|
|
375
|
+
};
|
|
376
|
+
/** Output of the native function `codebase-toml`. */
|
|
377
|
+
export type CodebaseTomlOutput = CodebaseBomOutput;
|
|
378
|
+
/**
|
|
379
|
+
* Input of the native function `codebase-trailing`.
|
|
380
|
+
*
|
|
381
|
+
* detect trailing whitespace
|
|
382
|
+
*/
|
|
383
|
+
export type CodebaseTrailingInput = {
|
|
384
|
+
readonly _changedFiles?: readonly string[];
|
|
385
|
+
readonly cwd?: string;
|
|
386
|
+
readonly dryRun?: boolean;
|
|
387
|
+
readonly exclude?: readonly string[];
|
|
388
|
+
readonly extensions?: readonly string[];
|
|
389
|
+
readonly fix?: boolean;
|
|
390
|
+
readonly root?: string;
|
|
391
|
+
readonly [key: string]: unknown;
|
|
392
|
+
};
|
|
393
|
+
/** Output of the native function `codebase-trailing`. */
|
|
394
|
+
export type CodebaseTrailingOutput = CodebaseBomOutput;
|
|
395
|
+
/**
|
|
396
|
+
* Input of the native function `codebase-yaml`.
|
|
397
|
+
*
|
|
398
|
+
* validate YAML syntax
|
|
399
|
+
*/
|
|
400
|
+
export type CodebaseYamlInput = {
|
|
401
|
+
readonly _changedFiles?: readonly string[];
|
|
402
|
+
readonly cwd?: string;
|
|
403
|
+
readonly dryRun?: boolean;
|
|
404
|
+
readonly exclude?: readonly string[];
|
|
405
|
+
readonly extensions?: readonly string[];
|
|
406
|
+
readonly fix?: boolean;
|
|
407
|
+
readonly root?: string;
|
|
408
|
+
readonly [key: string]: unknown;
|
|
409
|
+
};
|
|
410
|
+
/** Output of the native function `codebase-yaml`. */
|
|
411
|
+
export type CodebaseYamlOutput = CodebaseBomOutput;
|
|
412
|
+
/**
|
|
413
|
+
* Input of the native function `validate-bom`.
|
|
414
|
+
*
|
|
415
|
+
* remove UTF-8 byte order marks
|
|
416
|
+
*/
|
|
417
|
+
export type ValidateBomInput = {
|
|
418
|
+
readonly _changedFiles?: readonly string[];
|
|
419
|
+
readonly cwd?: string;
|
|
420
|
+
readonly dryRun?: boolean;
|
|
421
|
+
readonly exclude?: readonly string[];
|
|
422
|
+
readonly extensions?: readonly string[];
|
|
423
|
+
readonly fix?: boolean;
|
|
424
|
+
readonly root?: string;
|
|
425
|
+
readonly [key: string]: unknown;
|
|
426
|
+
};
|
|
427
|
+
/** Output of the native function `validate-bom`. */
|
|
428
|
+
export type ValidateBomOutput = CodebaseBomOutput;
|
|
429
|
+
/**
|
|
430
|
+
* Input of the native function `validate-case-conflict`.
|
|
431
|
+
*
|
|
432
|
+
* detect paths that differ only by case
|
|
433
|
+
*/
|
|
434
|
+
export type ValidateCaseConflictInput = {
|
|
435
|
+
readonly _changedFiles?: readonly string[];
|
|
436
|
+
readonly cwd?: string;
|
|
437
|
+
readonly dryRun?: boolean;
|
|
438
|
+
readonly exclude?: readonly string[];
|
|
439
|
+
readonly extensions?: readonly string[];
|
|
440
|
+
readonly fix?: boolean;
|
|
441
|
+
readonly root?: string;
|
|
442
|
+
readonly [key: string]: unknown;
|
|
443
|
+
};
|
|
444
|
+
/** Output of the native function `validate-case-conflict`. */
|
|
445
|
+
export type ValidateCaseConflictOutput = CodebaseBomOutput;
|
|
446
|
+
/**
|
|
447
|
+
* Input of the native function `validate-circular-deps`.
|
|
448
|
+
*
|
|
449
|
+
* detect circular dependencies between workspace packages
|
|
450
|
+
*/
|
|
451
|
+
export type ValidateCircularDepsInput = {
|
|
452
|
+
readonly cwd?: string;
|
|
453
|
+
readonly root?: string;
|
|
454
|
+
readonly [key: string]: unknown;
|
|
455
|
+
};
|
|
456
|
+
/** Output of the native function `validate-circular-deps`. */
|
|
457
|
+
export type ValidateCircularDepsOutput = CodebaseBomOutput;
|
|
458
|
+
/**
|
|
459
|
+
* Input of the native function `validate-code-conventions`.
|
|
460
|
+
*
|
|
461
|
+
* detect non-namespace imports, `||` defaults and `export *` beyond the recorded baseline
|
|
462
|
+
*/
|
|
463
|
+
export type ValidateCodeConventionsInput = {
|
|
464
|
+
readonly _changedFiles?: readonly string[];
|
|
465
|
+
readonly baseline?: string;
|
|
466
|
+
readonly cwd?: string;
|
|
467
|
+
readonly dryRun?: boolean;
|
|
468
|
+
readonly exclude?: readonly string[];
|
|
469
|
+
readonly extensions?: readonly string[];
|
|
470
|
+
readonly fix?: boolean;
|
|
471
|
+
readonly root?: string;
|
|
472
|
+
readonly [key: string]: unknown;
|
|
473
|
+
};
|
|
474
|
+
/** Output of the native function `validate-code-conventions`. */
|
|
475
|
+
export type ValidateCodeConventionsOutput = CodebaseBomOutput;
|
|
476
|
+
/**
|
|
477
|
+
* Input of the native function `validate-commit-msg`.
|
|
478
|
+
*
|
|
479
|
+
* validate the conventional commit format
|
|
480
|
+
*/
|
|
481
|
+
export type ValidateCommitMsgInput = {
|
|
482
|
+
readonly _args?: readonly string[];
|
|
483
|
+
readonly allowAsterisk?: boolean;
|
|
484
|
+
readonly allowMultipleScopes?: boolean;
|
|
485
|
+
readonly commitMsgFile?: string;
|
|
486
|
+
readonly cwd?: string;
|
|
487
|
+
readonly forceScope?: boolean;
|
|
488
|
+
readonly root?: string;
|
|
489
|
+
readonly types?: readonly string[];
|
|
490
|
+
readonly [key: string]: unknown;
|
|
491
|
+
};
|
|
492
|
+
/** Output of the native function `validate-commit-msg`. */
|
|
493
|
+
export type ValidateCommitMsgOutput = CodebaseBomOutput;
|
|
494
|
+
/**
|
|
495
|
+
* Input of the native function `validate-docs`.
|
|
496
|
+
*
|
|
497
|
+
* check the JSDoc of exported symbols
|
|
498
|
+
*/
|
|
499
|
+
export type ValidateDocsInput = {
|
|
500
|
+
readonly cwd?: string;
|
|
501
|
+
readonly requireExamples?: boolean;
|
|
502
|
+
readonly root?: string;
|
|
503
|
+
readonly [key: string]: unknown;
|
|
504
|
+
};
|
|
505
|
+
/** Output of the native function `validate-docs`. */
|
|
506
|
+
export type ValidateDocsOutput = CodebaseBomOutput;
|
|
507
|
+
/**
|
|
508
|
+
* Input of the native function `validate-eof`.
|
|
509
|
+
*
|
|
510
|
+
* ensure files end with exactly one newline
|
|
511
|
+
*/
|
|
512
|
+
export type ValidateEofInput = {
|
|
513
|
+
readonly _changedFiles?: readonly string[];
|
|
514
|
+
readonly cwd?: string;
|
|
515
|
+
readonly dryRun?: boolean;
|
|
516
|
+
readonly exclude?: readonly string[];
|
|
517
|
+
readonly extensions?: readonly string[];
|
|
518
|
+
readonly fix?: boolean;
|
|
519
|
+
readonly root?: string;
|
|
520
|
+
readonly [key: string]: unknown;
|
|
521
|
+
};
|
|
522
|
+
/** Output of the native function `validate-eof`. */
|
|
523
|
+
export type ValidateEofOutput = CodebaseBomOutput;
|
|
524
|
+
/**
|
|
525
|
+
* Input of the native function `validate-error-coverage`.
|
|
526
|
+
*
|
|
527
|
+
* verify that error-struct entries fill the required fields
|
|
528
|
+
*/
|
|
529
|
+
export type ValidateErrorCoverageInput = {
|
|
530
|
+
readonly _changedFiles?: readonly string[];
|
|
531
|
+
readonly cwd?: string;
|
|
532
|
+
readonly dryRun?: boolean;
|
|
533
|
+
readonly errorObjects?: readonly string[];
|
|
534
|
+
readonly exclude?: readonly string[];
|
|
535
|
+
readonly extensions?: readonly string[];
|
|
536
|
+
readonly file: string;
|
|
537
|
+
readonly fix?: boolean;
|
|
538
|
+
readonly requiredFields?: readonly string[];
|
|
539
|
+
readonly root?: string;
|
|
540
|
+
readonly [key: string]: unknown;
|
|
541
|
+
};
|
|
542
|
+
/** Output of the native function `validate-error-coverage`. */
|
|
543
|
+
export type ValidateErrorCoverageOutput = CodebaseBomOutput;
|
|
544
|
+
/**
|
|
545
|
+
* Input of the native function `validate-export-names`.
|
|
546
|
+
*
|
|
547
|
+
* check the export path naming conventions
|
|
548
|
+
*/
|
|
549
|
+
export type ValidateExportNamesInput = {
|
|
550
|
+
readonly cwd?: string;
|
|
551
|
+
readonly ignoreWords?: readonly string[];
|
|
552
|
+
readonly root?: string;
|
|
553
|
+
readonly [key: string]: unknown;
|
|
554
|
+
};
|
|
555
|
+
/** Output of the native function `validate-export-names`. */
|
|
556
|
+
export type ValidateExportNamesOutput = CodebaseBomOutput;
|
|
557
|
+
/**
|
|
558
|
+
* Input of the native function `validate-filenames`.
|
|
559
|
+
*
|
|
560
|
+
* enforce the filename conventions of the rules
|
|
561
|
+
*/
|
|
562
|
+
export type ValidateFilenamesInput = {
|
|
563
|
+
readonly _changedFiles?: readonly string[];
|
|
564
|
+
readonly cwd?: string;
|
|
565
|
+
readonly dryRun?: boolean;
|
|
566
|
+
readonly exclude?: readonly string[];
|
|
567
|
+
readonly extensions?: readonly string[];
|
|
568
|
+
readonly fix?: boolean;
|
|
569
|
+
readonly globalExcludes?: readonly string[];
|
|
570
|
+
readonly root?: string;
|
|
571
|
+
readonly rules?: ReadonlyArray<{
|
|
572
|
+
readonly convention: "kebab-case" | "snake_case";
|
|
573
|
+
readonly directory: string;
|
|
574
|
+
readonly exclude?: readonly string[];
|
|
575
|
+
readonly [key: string]: unknown;
|
|
576
|
+
}> | string;
|
|
577
|
+
readonly [key: string]: unknown;
|
|
578
|
+
};
|
|
579
|
+
/** Output of the native function `validate-filenames`. */
|
|
580
|
+
export type ValidateFilenamesOutput = CodebaseBomOutput;
|
|
581
|
+
/**
|
|
582
|
+
* Input of the native function `validate-json`.
|
|
583
|
+
*
|
|
584
|
+
* validate JSON and JSONC syntax
|
|
585
|
+
*/
|
|
586
|
+
export type ValidateJsonInput = {
|
|
587
|
+
readonly _changedFiles?: readonly string[];
|
|
588
|
+
readonly cwd?: string;
|
|
589
|
+
readonly dryRun?: boolean;
|
|
590
|
+
readonly exclude?: readonly string[];
|
|
591
|
+
readonly extensions?: readonly string[];
|
|
592
|
+
readonly fix?: boolean;
|
|
593
|
+
readonly root?: string;
|
|
594
|
+
readonly [key: string]: unknown;
|
|
595
|
+
};
|
|
596
|
+
/** Output of the native function `validate-json`. */
|
|
597
|
+
export type ValidateJsonOutput = CodebaseBomOutput;
|
|
598
|
+
/**
|
|
599
|
+
* Input of the native function `validate-large-files`.
|
|
600
|
+
*
|
|
601
|
+
* detect files over the size limit (maxKb)
|
|
602
|
+
*/
|
|
603
|
+
export type ValidateLargeFilesInput = {
|
|
604
|
+
readonly _changedFiles?: readonly string[];
|
|
605
|
+
readonly cwd?: string;
|
|
606
|
+
readonly dryRun?: boolean;
|
|
607
|
+
readonly exclude?: readonly string[];
|
|
608
|
+
readonly extensions?: readonly string[];
|
|
609
|
+
readonly fix?: boolean;
|
|
610
|
+
readonly maxKb?: number;
|
|
611
|
+
readonly root?: string;
|
|
612
|
+
readonly [key: string]: unknown;
|
|
613
|
+
};
|
|
614
|
+
/** Output of the native function `validate-large-files`. */
|
|
615
|
+
export type ValidateLargeFilesOutput = CodebaseBomOutput;
|
|
616
|
+
/**
|
|
617
|
+
* Input of the native function `validate-laroux-boundaries`.
|
|
618
|
+
*
|
|
619
|
+
* enforce the laroux package boundaries and the shrinking allowlist of deprecated-package importers
|
|
620
|
+
*/
|
|
621
|
+
export type ValidateLarouxBoundariesInput = {
|
|
622
|
+
readonly allowlist?: string;
|
|
623
|
+
readonly cwd?: string;
|
|
624
|
+
readonly exclude?: readonly string[];
|
|
625
|
+
readonly root?: string;
|
|
626
|
+
readonly [key: string]: unknown;
|
|
627
|
+
};
|
|
628
|
+
/** Output of the native function `validate-laroux-boundaries`. */
|
|
629
|
+
export type ValidateLarouxBoundariesOutput = CodebaseBomOutput;
|
|
630
|
+
/**
|
|
631
|
+
* Input of the native function `validate-licenses`.
|
|
632
|
+
*
|
|
633
|
+
* check the copyright header of JS and TS files
|
|
634
|
+
*/
|
|
635
|
+
export type ValidateLicensesInput = {
|
|
636
|
+
readonly _changedFiles?: readonly string[];
|
|
637
|
+
readonly cwd?: string;
|
|
638
|
+
readonly dryRun?: boolean;
|
|
639
|
+
readonly exclude?: readonly string[];
|
|
640
|
+
readonly extensions?: readonly string[];
|
|
641
|
+
readonly fix?: boolean;
|
|
642
|
+
readonly root?: string;
|
|
643
|
+
readonly [key: string]: unknown;
|
|
644
|
+
};
|
|
645
|
+
/** Output of the native function `validate-licenses`. */
|
|
646
|
+
export type ValidateLicensesOutput = CodebaseBomOutput;
|
|
647
|
+
/**
|
|
648
|
+
* Input of the native function `validate-line-endings`.
|
|
649
|
+
*
|
|
650
|
+
* normalize line endings to LF
|
|
651
|
+
*/
|
|
652
|
+
export type ValidateLineEndingsInput = {
|
|
653
|
+
readonly _changedFiles?: readonly string[];
|
|
654
|
+
readonly cwd?: string;
|
|
655
|
+
readonly dryRun?: boolean;
|
|
656
|
+
readonly exclude?: readonly string[];
|
|
657
|
+
readonly extensions?: readonly string[];
|
|
658
|
+
readonly fix?: boolean;
|
|
659
|
+
readonly root?: string;
|
|
660
|
+
readonly [key: string]: unknown;
|
|
661
|
+
};
|
|
662
|
+
/** Output of the native function `validate-line-endings`. */
|
|
663
|
+
export type ValidateLineEndingsOutput = CodebaseBomOutput;
|
|
664
|
+
/**
|
|
665
|
+
* Input of the native function `validate-merge-conflict`.
|
|
666
|
+
*
|
|
667
|
+
* detect merge conflict markers
|
|
668
|
+
*/
|
|
669
|
+
export type ValidateMergeConflictInput = {
|
|
670
|
+
readonly _changedFiles?: readonly string[];
|
|
671
|
+
readonly cwd?: string;
|
|
672
|
+
readonly dryRun?: boolean;
|
|
673
|
+
readonly exclude?: readonly string[];
|
|
674
|
+
readonly extensions?: readonly string[];
|
|
675
|
+
readonly fix?: boolean;
|
|
676
|
+
readonly root?: string;
|
|
677
|
+
readonly [key: string]: unknown;
|
|
678
|
+
};
|
|
679
|
+
/** Output of the native function `validate-merge-conflict`. */
|
|
680
|
+
export type ValidateMergeConflictOutput = CodebaseBomOutput;
|
|
681
|
+
/**
|
|
682
|
+
* Input of the native function `validate-mod-exports`.
|
|
683
|
+
*
|
|
684
|
+
* check that every source file is reached from an entry point
|
|
685
|
+
*/
|
|
686
|
+
export type ValidateModExportsInput = {
|
|
687
|
+
readonly cwd?: string;
|
|
688
|
+
readonly root?: string;
|
|
689
|
+
readonly [key: string]: unknown;
|
|
690
|
+
};
|
|
691
|
+
/** Output of the native function `validate-mod-exports`. */
|
|
692
|
+
export type ValidateModExportsOutput = CodebaseBomOutput;
|
|
693
|
+
/**
|
|
694
|
+
* Input of the native function `validate-naming-and-todos`.
|
|
695
|
+
*
|
|
696
|
+
* enforce camelCase names and task-tagged TODO comments
|
|
697
|
+
*/
|
|
698
|
+
export type ValidateNamingAndTodosInput = {
|
|
699
|
+
readonly _changedFiles?: readonly string[];
|
|
700
|
+
readonly allowNames?: readonly string[];
|
|
701
|
+
readonly cwd?: string;
|
|
702
|
+
readonly dryRun?: boolean;
|
|
703
|
+
readonly exclude?: readonly string[];
|
|
704
|
+
readonly extensions?: readonly string[];
|
|
705
|
+
readonly fix?: boolean;
|
|
706
|
+
readonly root?: string;
|
|
707
|
+
readonly [key: string]: unknown;
|
|
708
|
+
};
|
|
709
|
+
/** Output of the native function `validate-naming-and-todos`. */
|
|
710
|
+
export type ValidateNamingAndTodosOutput = CodebaseBomOutput;
|
|
711
|
+
/**
|
|
712
|
+
* Input of the native function `validate-runtime-js-apis`.
|
|
713
|
+
*
|
|
714
|
+
* detect runtime globals used instead of @eserstack/standards/cross-runtime
|
|
715
|
+
*/
|
|
716
|
+
export type ValidateRuntimeJsApisInput = {
|
|
717
|
+
readonly _changedFiles?: readonly string[];
|
|
718
|
+
readonly cwd?: string;
|
|
719
|
+
readonly dryRun?: boolean;
|
|
720
|
+
readonly exclude?: readonly string[];
|
|
721
|
+
readonly extensions?: readonly string[];
|
|
722
|
+
readonly fix?: boolean;
|
|
723
|
+
readonly root?: string;
|
|
724
|
+
readonly [key: string]: unknown;
|
|
725
|
+
};
|
|
726
|
+
/** Output of the native function `validate-runtime-js-apis`. */
|
|
727
|
+
export type ValidateRuntimeJsApisOutput = CodebaseBomOutput;
|
|
728
|
+
/**
|
|
729
|
+
* Input of the native function `validate-secrets`.
|
|
730
|
+
*
|
|
731
|
+
* detect credentials and private keys
|
|
732
|
+
*/
|
|
733
|
+
export type ValidateSecretsInput = {
|
|
734
|
+
readonly _changedFiles?: readonly string[];
|
|
735
|
+
readonly cwd?: string;
|
|
736
|
+
readonly dryRun?: boolean;
|
|
737
|
+
readonly exclude?: readonly string[];
|
|
738
|
+
readonly extensions?: readonly string[];
|
|
739
|
+
readonly fix?: boolean;
|
|
740
|
+
readonly root?: string;
|
|
741
|
+
readonly [key: string]: unknown;
|
|
742
|
+
};
|
|
743
|
+
/** Output of the native function `validate-secrets`. */
|
|
744
|
+
export type ValidateSecretsOutput = CodebaseBomOutput;
|
|
745
|
+
/**
|
|
746
|
+
* Input of the native function `validate-self-imports`.
|
|
747
|
+
*
|
|
748
|
+
* detect a package importing itself by its published name
|
|
749
|
+
*/
|
|
750
|
+
export type ValidateSelfImportsInput = {
|
|
751
|
+
readonly _changedFiles?: readonly string[];
|
|
752
|
+
readonly cwd?: string;
|
|
753
|
+
readonly dryRun?: boolean;
|
|
754
|
+
readonly exclude?: readonly string[];
|
|
755
|
+
readonly extensions?: readonly string[];
|
|
756
|
+
readonly fix?: boolean;
|
|
757
|
+
readonly root?: string;
|
|
758
|
+
readonly [key: string]: unknown;
|
|
759
|
+
};
|
|
760
|
+
/** Output of the native function `validate-self-imports`. */
|
|
761
|
+
export type ValidateSelfImportsOutput = CodebaseBomOutput;
|
|
762
|
+
/**
|
|
763
|
+
* Input of the native function `validate-server-loc`.
|
|
764
|
+
*
|
|
765
|
+
* fail when a non-test file of a directory exceeds the line ceiling
|
|
766
|
+
*/
|
|
767
|
+
export type ValidateServerLocInput = {
|
|
768
|
+
readonly _changedFiles?: readonly string[];
|
|
769
|
+
readonly cwd?: string;
|
|
770
|
+
readonly directory: string;
|
|
771
|
+
readonly dryRun?: boolean;
|
|
772
|
+
readonly exclude?: readonly string[];
|
|
773
|
+
readonly excludeSuffix?: string;
|
|
774
|
+
readonly extension?: string;
|
|
775
|
+
readonly extensions?: readonly string[];
|
|
776
|
+
readonly fix?: boolean;
|
|
777
|
+
readonly maxLines?: number;
|
|
778
|
+
readonly root?: string;
|
|
779
|
+
readonly [key: string]: unknown;
|
|
780
|
+
};
|
|
781
|
+
/** Output of the native function `validate-server-loc`. */
|
|
782
|
+
export type ValidateServerLocOutput = CodebaseBomOutput;
|
|
783
|
+
/**
|
|
784
|
+
* Input of the native function `validate-shebangs`.
|
|
785
|
+
*
|
|
786
|
+
* validate shebang lines (no checks yet)
|
|
787
|
+
*/
|
|
788
|
+
export type ValidateShebangsInput = {
|
|
789
|
+
readonly _changedFiles?: readonly string[];
|
|
790
|
+
readonly cwd?: string;
|
|
791
|
+
readonly dryRun?: boolean;
|
|
792
|
+
readonly exclude?: readonly string[];
|
|
793
|
+
readonly extensions?: readonly string[];
|
|
794
|
+
readonly fix?: boolean;
|
|
795
|
+
readonly root?: string;
|
|
796
|
+
readonly [key: string]: unknown;
|
|
797
|
+
};
|
|
798
|
+
/** Output of the native function `validate-shebangs`. */
|
|
799
|
+
export type ValidateShebangsOutput = CodebaseBomOutput;
|
|
800
|
+
/**
|
|
801
|
+
* Input of the native function `validate-submodules`.
|
|
802
|
+
*
|
|
803
|
+
* detect git submodules
|
|
804
|
+
*/
|
|
805
|
+
export type ValidateSubmodulesInput = {
|
|
806
|
+
readonly _changedFiles?: readonly string[];
|
|
807
|
+
readonly cwd?: string;
|
|
808
|
+
readonly dryRun?: boolean;
|
|
809
|
+
readonly exclude?: readonly string[];
|
|
810
|
+
readonly extensions?: readonly string[];
|
|
811
|
+
readonly fix?: boolean;
|
|
812
|
+
readonly root?: string;
|
|
813
|
+
readonly [key: string]: unknown;
|
|
814
|
+
};
|
|
815
|
+
/** Output of the native function `validate-submodules`. */
|
|
816
|
+
export type ValidateSubmodulesOutput = CodebaseBomOutput;
|
|
817
|
+
/**
|
|
818
|
+
* Input of the native function `validate-symlinks`.
|
|
819
|
+
*
|
|
820
|
+
* detect broken symbolic links
|
|
821
|
+
*/
|
|
822
|
+
export type ValidateSymlinksInput = {
|
|
823
|
+
readonly _changedFiles?: readonly string[];
|
|
824
|
+
readonly cwd?: string;
|
|
825
|
+
readonly dryRun?: boolean;
|
|
826
|
+
readonly exclude?: readonly string[];
|
|
827
|
+
readonly extensions?: readonly string[];
|
|
828
|
+
readonly fix?: boolean;
|
|
829
|
+
readonly root?: string;
|
|
830
|
+
readonly [key: string]: unknown;
|
|
831
|
+
};
|
|
832
|
+
/** Output of the native function `validate-symlinks`. */
|
|
833
|
+
export type ValidateSymlinksOutput = CodebaseBomOutput;
|
|
834
|
+
/**
|
|
835
|
+
* Input of the native function `validate-toml`.
|
|
836
|
+
*
|
|
837
|
+
* validate TOML syntax
|
|
838
|
+
*/
|
|
839
|
+
export type ValidateTomlInput = {
|
|
840
|
+
readonly _changedFiles?: readonly string[];
|
|
841
|
+
readonly cwd?: string;
|
|
842
|
+
readonly dryRun?: boolean;
|
|
843
|
+
readonly exclude?: readonly string[];
|
|
844
|
+
readonly extensions?: readonly string[];
|
|
845
|
+
readonly fix?: boolean;
|
|
846
|
+
readonly root?: string;
|
|
847
|
+
readonly [key: string]: unknown;
|
|
848
|
+
};
|
|
849
|
+
/** Output of the native function `validate-toml`. */
|
|
850
|
+
export type ValidateTomlOutput = CodebaseBomOutput;
|
|
851
|
+
/**
|
|
852
|
+
* Input of the native function `validate-trailing-whitespace`.
|
|
853
|
+
*
|
|
854
|
+
* remove trailing whitespace from lines
|
|
855
|
+
*/
|
|
856
|
+
export type ValidateTrailingWhitespaceInput = {
|
|
857
|
+
readonly _changedFiles?: readonly string[];
|
|
858
|
+
readonly cwd?: string;
|
|
859
|
+
readonly dryRun?: boolean;
|
|
860
|
+
readonly exclude?: readonly string[];
|
|
861
|
+
readonly extensions?: readonly string[];
|
|
862
|
+
readonly fix?: boolean;
|
|
863
|
+
readonly root?: string;
|
|
864
|
+
readonly [key: string]: unknown;
|
|
865
|
+
};
|
|
866
|
+
/** Output of the native function `validate-trailing-whitespace`. */
|
|
867
|
+
export type ValidateTrailingWhitespaceOutput = CodebaseBomOutput;
|
|
868
|
+
/**
|
|
869
|
+
* Input of the native function `validate-yaml`.
|
|
870
|
+
*
|
|
871
|
+
* validate YAML syntax (allowMultipleDocuments)
|
|
872
|
+
*/
|
|
873
|
+
export type ValidateYamlInput = {
|
|
874
|
+
readonly _changedFiles?: readonly string[];
|
|
875
|
+
readonly allowMultipleDocuments?: boolean;
|
|
876
|
+
readonly cwd?: string;
|
|
877
|
+
readonly dryRun?: boolean;
|
|
878
|
+
readonly exclude?: readonly string[];
|
|
879
|
+
readonly extensions?: readonly string[];
|
|
880
|
+
readonly fix?: boolean;
|
|
881
|
+
readonly root?: string;
|
|
882
|
+
readonly [key: string]: unknown;
|
|
883
|
+
};
|
|
884
|
+
/** Output of the native function `validate-yaml`. */
|
|
885
|
+
export type ValidateYamlOutput = CodebaseBomOutput;
|
|
886
|
+
/** The native functions of this package, by name. */
|
|
887
|
+
export type NativeFunctions = {
|
|
888
|
+
readonly "codebase-bom": {
|
|
889
|
+
readonly input: CodebaseBomInput;
|
|
890
|
+
readonly output: CodebaseBomOutput;
|
|
891
|
+
};
|
|
892
|
+
readonly "codebase-case-conflict": {
|
|
893
|
+
readonly input: CodebaseCaseConflictInput;
|
|
894
|
+
readonly output: CodebaseCaseConflictOutput;
|
|
895
|
+
};
|
|
896
|
+
readonly "codebase-code-conventions": {
|
|
897
|
+
readonly input: CodebaseCodeConventionsInput;
|
|
898
|
+
readonly output: CodebaseCodeConventionsOutput;
|
|
899
|
+
};
|
|
900
|
+
readonly "codebase-eof": {
|
|
901
|
+
readonly input: CodebaseEofInput;
|
|
902
|
+
readonly output: CodebaseEofOutput;
|
|
903
|
+
};
|
|
904
|
+
readonly "codebase-error-coverage": {
|
|
905
|
+
readonly input: CodebaseErrorCoverageInput;
|
|
906
|
+
readonly output: CodebaseErrorCoverageOutput;
|
|
907
|
+
};
|
|
908
|
+
readonly "codebase-filenames": {
|
|
909
|
+
readonly input: CodebaseFilenamesInput;
|
|
910
|
+
readonly output: CodebaseFilenamesOutput;
|
|
911
|
+
};
|
|
912
|
+
readonly "codebase-json": {
|
|
913
|
+
readonly input: CodebaseJsonInput;
|
|
914
|
+
readonly output: CodebaseJsonOutput;
|
|
915
|
+
};
|
|
916
|
+
readonly "codebase-large-file": {
|
|
917
|
+
readonly input: CodebaseLargeFileInput;
|
|
918
|
+
readonly output: CodebaseLargeFileOutput;
|
|
919
|
+
};
|
|
920
|
+
readonly "codebase-license": {
|
|
921
|
+
readonly input: CodebaseLicenseInput;
|
|
922
|
+
readonly output: CodebaseLicenseOutput;
|
|
923
|
+
};
|
|
924
|
+
readonly "codebase-line-endings": {
|
|
925
|
+
readonly input: CodebaseLineEndingsInput;
|
|
926
|
+
readonly output: CodebaseLineEndingsOutput;
|
|
927
|
+
};
|
|
928
|
+
readonly "codebase-merge-conflicts": {
|
|
929
|
+
readonly input: CodebaseMergeConflictsInput;
|
|
930
|
+
readonly output: CodebaseMergeConflictsOutput;
|
|
931
|
+
};
|
|
932
|
+
readonly "codebase-naming-and-todos": {
|
|
933
|
+
readonly input: CodebaseNamingAndTodosInput;
|
|
934
|
+
readonly output: CodebaseNamingAndTodosOutput;
|
|
935
|
+
};
|
|
936
|
+
readonly "codebase-runtime-js-apis": {
|
|
937
|
+
readonly input: CodebaseRuntimeJsApisInput;
|
|
938
|
+
readonly output: CodebaseRuntimeJsApisOutput;
|
|
939
|
+
};
|
|
940
|
+
readonly "codebase-secrets": {
|
|
941
|
+
readonly input: CodebaseSecretsInput;
|
|
942
|
+
readonly output: CodebaseSecretsOutput;
|
|
943
|
+
};
|
|
944
|
+
readonly "codebase-self-imports": {
|
|
945
|
+
readonly input: CodebaseSelfImportsInput;
|
|
946
|
+
readonly output: CodebaseSelfImportsOutput;
|
|
947
|
+
};
|
|
948
|
+
readonly "codebase-server-loc": {
|
|
949
|
+
readonly input: CodebaseServerLocInput;
|
|
950
|
+
readonly output: CodebaseServerLocOutput;
|
|
951
|
+
};
|
|
952
|
+
readonly "codebase-shebangs": {
|
|
953
|
+
readonly input: CodebaseShebangsInput;
|
|
954
|
+
readonly output: CodebaseShebangsOutput;
|
|
955
|
+
};
|
|
956
|
+
readonly "codebase-submodules": {
|
|
957
|
+
readonly input: CodebaseSubmodulesInput;
|
|
958
|
+
readonly output: CodebaseSubmodulesOutput;
|
|
959
|
+
};
|
|
960
|
+
readonly "codebase-symlinks": {
|
|
961
|
+
readonly input: CodebaseSymlinksInput;
|
|
962
|
+
readonly output: CodebaseSymlinksOutput;
|
|
963
|
+
};
|
|
964
|
+
readonly "codebase-toml": {
|
|
965
|
+
readonly input: CodebaseTomlInput;
|
|
966
|
+
readonly output: CodebaseTomlOutput;
|
|
967
|
+
};
|
|
968
|
+
readonly "codebase-trailing": {
|
|
969
|
+
readonly input: CodebaseTrailingInput;
|
|
970
|
+
readonly output: CodebaseTrailingOutput;
|
|
971
|
+
};
|
|
972
|
+
readonly "codebase-yaml": {
|
|
973
|
+
readonly input: CodebaseYamlInput;
|
|
974
|
+
readonly output: CodebaseYamlOutput;
|
|
975
|
+
};
|
|
976
|
+
readonly "validate-bom": {
|
|
977
|
+
readonly input: ValidateBomInput;
|
|
978
|
+
readonly output: ValidateBomOutput;
|
|
979
|
+
};
|
|
980
|
+
readonly "validate-case-conflict": {
|
|
981
|
+
readonly input: ValidateCaseConflictInput;
|
|
982
|
+
readonly output: ValidateCaseConflictOutput;
|
|
983
|
+
};
|
|
984
|
+
readonly "validate-circular-deps": {
|
|
985
|
+
readonly input: ValidateCircularDepsInput;
|
|
986
|
+
readonly output: ValidateCircularDepsOutput;
|
|
987
|
+
};
|
|
988
|
+
readonly "validate-code-conventions": {
|
|
989
|
+
readonly input: ValidateCodeConventionsInput;
|
|
990
|
+
readonly output: ValidateCodeConventionsOutput;
|
|
991
|
+
};
|
|
992
|
+
readonly "validate-commit-msg": {
|
|
993
|
+
readonly input: ValidateCommitMsgInput;
|
|
994
|
+
readonly output: ValidateCommitMsgOutput;
|
|
995
|
+
};
|
|
996
|
+
readonly "validate-docs": {
|
|
997
|
+
readonly input: ValidateDocsInput;
|
|
998
|
+
readonly output: ValidateDocsOutput;
|
|
999
|
+
};
|
|
1000
|
+
readonly "validate-eof": {
|
|
1001
|
+
readonly input: ValidateEofInput;
|
|
1002
|
+
readonly output: ValidateEofOutput;
|
|
1003
|
+
};
|
|
1004
|
+
readonly "validate-error-coverage": {
|
|
1005
|
+
readonly input: ValidateErrorCoverageInput;
|
|
1006
|
+
readonly output: ValidateErrorCoverageOutput;
|
|
1007
|
+
};
|
|
1008
|
+
readonly "validate-export-names": {
|
|
1009
|
+
readonly input: ValidateExportNamesInput;
|
|
1010
|
+
readonly output: ValidateExportNamesOutput;
|
|
1011
|
+
};
|
|
1012
|
+
readonly "validate-filenames": {
|
|
1013
|
+
readonly input: ValidateFilenamesInput;
|
|
1014
|
+
readonly output: ValidateFilenamesOutput;
|
|
1015
|
+
};
|
|
1016
|
+
readonly "validate-json": {
|
|
1017
|
+
readonly input: ValidateJsonInput;
|
|
1018
|
+
readonly output: ValidateJsonOutput;
|
|
1019
|
+
};
|
|
1020
|
+
readonly "validate-large-files": {
|
|
1021
|
+
readonly input: ValidateLargeFilesInput;
|
|
1022
|
+
readonly output: ValidateLargeFilesOutput;
|
|
1023
|
+
};
|
|
1024
|
+
readonly "validate-laroux-boundaries": {
|
|
1025
|
+
readonly input: ValidateLarouxBoundariesInput;
|
|
1026
|
+
readonly output: ValidateLarouxBoundariesOutput;
|
|
1027
|
+
};
|
|
1028
|
+
readonly "validate-licenses": {
|
|
1029
|
+
readonly input: ValidateLicensesInput;
|
|
1030
|
+
readonly output: ValidateLicensesOutput;
|
|
1031
|
+
};
|
|
1032
|
+
readonly "validate-line-endings": {
|
|
1033
|
+
readonly input: ValidateLineEndingsInput;
|
|
1034
|
+
readonly output: ValidateLineEndingsOutput;
|
|
1035
|
+
};
|
|
1036
|
+
readonly "validate-merge-conflict": {
|
|
1037
|
+
readonly input: ValidateMergeConflictInput;
|
|
1038
|
+
readonly output: ValidateMergeConflictOutput;
|
|
1039
|
+
};
|
|
1040
|
+
readonly "validate-mod-exports": {
|
|
1041
|
+
readonly input: ValidateModExportsInput;
|
|
1042
|
+
readonly output: ValidateModExportsOutput;
|
|
1043
|
+
};
|
|
1044
|
+
readonly "validate-naming-and-todos": {
|
|
1045
|
+
readonly input: ValidateNamingAndTodosInput;
|
|
1046
|
+
readonly output: ValidateNamingAndTodosOutput;
|
|
1047
|
+
};
|
|
1048
|
+
readonly "validate-runtime-js-apis": {
|
|
1049
|
+
readonly input: ValidateRuntimeJsApisInput;
|
|
1050
|
+
readonly output: ValidateRuntimeJsApisOutput;
|
|
1051
|
+
};
|
|
1052
|
+
readonly "validate-secrets": {
|
|
1053
|
+
readonly input: ValidateSecretsInput;
|
|
1054
|
+
readonly output: ValidateSecretsOutput;
|
|
1055
|
+
};
|
|
1056
|
+
readonly "validate-self-imports": {
|
|
1057
|
+
readonly input: ValidateSelfImportsInput;
|
|
1058
|
+
readonly output: ValidateSelfImportsOutput;
|
|
1059
|
+
};
|
|
1060
|
+
readonly "validate-server-loc": {
|
|
1061
|
+
readonly input: ValidateServerLocInput;
|
|
1062
|
+
readonly output: ValidateServerLocOutput;
|
|
1063
|
+
};
|
|
1064
|
+
readonly "validate-shebangs": {
|
|
1065
|
+
readonly input: ValidateShebangsInput;
|
|
1066
|
+
readonly output: ValidateShebangsOutput;
|
|
1067
|
+
};
|
|
1068
|
+
readonly "validate-submodules": {
|
|
1069
|
+
readonly input: ValidateSubmodulesInput;
|
|
1070
|
+
readonly output: ValidateSubmodulesOutput;
|
|
1071
|
+
};
|
|
1072
|
+
readonly "validate-symlinks": {
|
|
1073
|
+
readonly input: ValidateSymlinksInput;
|
|
1074
|
+
readonly output: ValidateSymlinksOutput;
|
|
1075
|
+
};
|
|
1076
|
+
readonly "validate-toml": {
|
|
1077
|
+
readonly input: ValidateTomlInput;
|
|
1078
|
+
readonly output: ValidateTomlOutput;
|
|
1079
|
+
};
|
|
1080
|
+
readonly "validate-trailing-whitespace": {
|
|
1081
|
+
readonly input: ValidateTrailingWhitespaceInput;
|
|
1082
|
+
readonly output: ValidateTrailingWhitespaceOutput;
|
|
1083
|
+
};
|
|
1084
|
+
readonly "validate-yaml": {
|
|
1085
|
+
readonly input: ValidateYamlInput;
|
|
1086
|
+
readonly output: ValidateYamlOutput;
|
|
1087
|
+
};
|
|
1088
|
+
};
|