@akanjs/devkit 0.0.39 → 0.0.40
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/index.d.ts +24 -0
- package/index.js +21 -1950
- package/package.json +2 -20
- package/src/aiEditor.d.ts +10 -0
- package/src/aiEditor.js +61 -0
- package/src/auth.d.ts +12 -0
- package/src/auth.js +79 -0
- package/src/baseDevEnv.d.ts +12 -0
- package/src/baseDevEnv.js +50 -0
- package/src/capacitorApp.d.ts +27 -0
- package/src/capacitorApp.js +186 -0
- package/src/constants.d.ts +21 -0
- package/src/constants.js +47 -0
- package/src/createTunnel.d.ts +8 -0
- package/src/createTunnel.js +47 -0
- package/src/dependencyScanner.d.ts +11 -0
- package/src/dependencyScanner.js +171 -0
- package/src/executors.d.ts +279 -0
- package/src/executors.js +715 -0
- package/src/extractDeps.d.ts +7 -0
- package/src/extractDeps.js +114 -0
- package/src/getCredentials.d.ts +18 -0
- package/src/getCredentials.js +43 -0
- package/src/getDependencies.d.ts +6 -0
- package/src/getDependencies.js +67 -0
- package/src/getModelFileData.d.ts +17 -0
- package/src/getModelFileData.js +67 -0
- package/src/getRelatedCnsts.d.ts +11 -0
- package/src/getRelatedCnsts.js +145 -0
- package/src/index.d.ts +101 -0
- package/src/index.js +55 -0
- package/src/installExternalLib.d.ts +8 -0
- package/src/installExternalLib.js +34 -0
- package/src/selectModel.d.ts +3 -0
- package/src/selectModel.js +50 -0
- package/src/streamAi.d.ts +7 -0
- package/src/streamAi.js +69 -0
- package/src/types.d.ts +20 -0
- package/src/types.js +15 -0
- package/src/uploadRelease.d.ts +11 -0
- package/src/uploadRelease.js +82 -0
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
#!/usr/bin/env ts-node
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
9
|
+
var __export = (target, all) => {
|
|
10
|
+
for (var name in all)
|
|
11
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
12
|
+
};
|
|
13
|
+
var __copyProps = (to, from, except, desc) => {
|
|
14
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
15
|
+
for (let key of __getOwnPropNames(from))
|
|
16
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
17
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
18
|
+
}
|
|
19
|
+
return to;
|
|
20
|
+
};
|
|
21
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
22
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
23
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
24
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
25
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
26
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
27
|
+
mod
|
|
28
|
+
));
|
|
29
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
30
|
+
var dependencyScanner_exports = {};
|
|
31
|
+
__export(dependencyScanner_exports, {
|
|
32
|
+
TypeScriptDependencyScanner: () => TypeScriptDependencyScanner
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(dependencyScanner_exports);
|
|
35
|
+
var fs = __toESM(require("fs"));
|
|
36
|
+
var path = __toESM(require("path"));
|
|
37
|
+
var ts = __toESM(require("typescript"));
|
|
38
|
+
class TypeScriptDependencyScanner {
|
|
39
|
+
static {
|
|
40
|
+
__name(this, "TypeScriptDependencyScanner");
|
|
41
|
+
}
|
|
42
|
+
directory;
|
|
43
|
+
#fileDependencies;
|
|
44
|
+
#visitedFiles;
|
|
45
|
+
constructor(directory) {
|
|
46
|
+
this.directory = directory;
|
|
47
|
+
this.#fileDependencies = /* @__PURE__ */ new Map();
|
|
48
|
+
this.#visitedFiles = /* @__PURE__ */ new Set();
|
|
49
|
+
}
|
|
50
|
+
async getImportSets(depSets) {
|
|
51
|
+
const fileDependencies = await this.getDependencies();
|
|
52
|
+
const importedDepSets = new Array(depSets.length);
|
|
53
|
+
for (let i = 0; i < depSets.length; i++) importedDepSets[i] = /* @__PURE__ */ new Set();
|
|
54
|
+
fileDependencies.forEach((imps) => {
|
|
55
|
+
imps.forEach((imp) => {
|
|
56
|
+
if (imp.startsWith(".")) return;
|
|
57
|
+
const moduleName = imp;
|
|
58
|
+
const moduleNameParts = moduleName.split("/");
|
|
59
|
+
const subModuleLength = moduleNameParts.length;
|
|
60
|
+
for (let i = 0; i < subModuleLength; i++) {
|
|
61
|
+
const importName = moduleNameParts.slice(0, i + 1).join("/");
|
|
62
|
+
for (let j = 0; j < depSets.length; j++) {
|
|
63
|
+
if (depSets[j].has(importName)) {
|
|
64
|
+
importedDepSets[j].add(importName);
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
});
|
|
70
|
+
});
|
|
71
|
+
return importedDepSets;
|
|
72
|
+
}
|
|
73
|
+
async getDependencies() {
|
|
74
|
+
this.#fileDependencies.clear();
|
|
75
|
+
this.#visitedFiles.clear();
|
|
76
|
+
const files = await this.#findTypeScriptFiles(this.directory);
|
|
77
|
+
for (const file of files) await this.#analyzeFile(file, this.directory);
|
|
78
|
+
return this.#fileDependencies;
|
|
79
|
+
}
|
|
80
|
+
async #findTypeScriptFiles(directory) {
|
|
81
|
+
const files = [];
|
|
82
|
+
const processDirectory = /* @__PURE__ */ __name(async (dir) => {
|
|
83
|
+
const entries = await fs.promises.readdir(dir, {
|
|
84
|
+
withFileTypes: true
|
|
85
|
+
});
|
|
86
|
+
for (const entry of entries) {
|
|
87
|
+
const fullPath = path.join(dir, entry.name);
|
|
88
|
+
if (entry.isDirectory()) {
|
|
89
|
+
if (![
|
|
90
|
+
"node_modules",
|
|
91
|
+
"dist",
|
|
92
|
+
"build",
|
|
93
|
+
".git",
|
|
94
|
+
".next",
|
|
95
|
+
"public",
|
|
96
|
+
"ios",
|
|
97
|
+
"android"
|
|
98
|
+
].includes(entry.name)) await processDirectory(fullPath);
|
|
99
|
+
} else if (entry.isFile() && (entry.name.endsWith(".ts") || entry.name.endsWith(".tsx"))) files.push(fullPath);
|
|
100
|
+
}
|
|
101
|
+
}, "processDirectory");
|
|
102
|
+
await processDirectory(directory);
|
|
103
|
+
return files;
|
|
104
|
+
}
|
|
105
|
+
async #analyzeFile(filePath, baseDir) {
|
|
106
|
+
if (this.#visitedFiles.has(filePath)) return;
|
|
107
|
+
this.#visitedFiles.add(filePath);
|
|
108
|
+
try {
|
|
109
|
+
const fileContent = await fs.promises.readFile(filePath, "utf-8");
|
|
110
|
+
const imports = this.#extractImports(fileContent, filePath);
|
|
111
|
+
const resolvedImports = imports.map((importPath) => {
|
|
112
|
+
if (importPath.startsWith(".")) {
|
|
113
|
+
const resolvedPath = "./" + path.join(path.relative(baseDir, filePath), importPath);
|
|
114
|
+
return this.#ensureExtension(resolvedPath);
|
|
115
|
+
}
|
|
116
|
+
return importPath;
|
|
117
|
+
});
|
|
118
|
+
const relativePath = path.relative(baseDir, filePath);
|
|
119
|
+
this.#fileDependencies.set(relativePath, resolvedImports);
|
|
120
|
+
} catch (error) {
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
#ensureExtension(filePath) {
|
|
124
|
+
if (fs.existsSync(`${filePath}.ts`)) return `${filePath}.ts`;
|
|
125
|
+
else if (fs.existsSync(`${filePath}.tsx`)) return `${filePath}.tsx`;
|
|
126
|
+
else if (fs.existsSync(filePath)) return filePath;
|
|
127
|
+
return `${filePath}.ts`;
|
|
128
|
+
}
|
|
129
|
+
#extractImports(source, filePath) {
|
|
130
|
+
const imports = [];
|
|
131
|
+
const sourceFile = ts.createSourceFile(filePath, source, ts.ScriptTarget.Latest, true);
|
|
132
|
+
const visit = /* @__PURE__ */ __name((node) => {
|
|
133
|
+
if (ts.isImportDeclaration(node)) {
|
|
134
|
+
const moduleSpecifier = node.moduleSpecifier;
|
|
135
|
+
if (ts.isStringLiteral(moduleSpecifier)) imports.push(moduleSpecifier.text);
|
|
136
|
+
}
|
|
137
|
+
ts.forEachChild(node, visit);
|
|
138
|
+
}, "visit");
|
|
139
|
+
visit(sourceFile);
|
|
140
|
+
return imports;
|
|
141
|
+
}
|
|
142
|
+
generateDependencyGraph() {
|
|
143
|
+
let graph = "Dependency Graph:\n\n";
|
|
144
|
+
for (const [file, imports] of this.#fileDependencies.entries()) {
|
|
145
|
+
graph += `${file}:
|
|
146
|
+
`;
|
|
147
|
+
const projectImports = imports.filter((i) => !i.startsWith("react") && !i.startsWith("@"));
|
|
148
|
+
const externalImports = imports.filter((i) => i.startsWith("react") || i.startsWith("@"));
|
|
149
|
+
if (projectImports.length > 0) {
|
|
150
|
+
graph += " Project dependencies:\n";
|
|
151
|
+
projectImports.forEach((imp) => {
|
|
152
|
+
graph += ` \u2192 ${imp}
|
|
153
|
+
`;
|
|
154
|
+
});
|
|
155
|
+
}
|
|
156
|
+
if (externalImports.length > 0) {
|
|
157
|
+
graph += " External dependencies:\n";
|
|
158
|
+
externalImports.forEach((imp) => {
|
|
159
|
+
graph += ` \u2192 ${imp}
|
|
160
|
+
`;
|
|
161
|
+
});
|
|
162
|
+
}
|
|
163
|
+
graph += "\n";
|
|
164
|
+
}
|
|
165
|
+
return graph;
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
169
|
+
0 && (module.exports = {
|
|
170
|
+
TypeScriptDependencyScanner
|
|
171
|
+
});
|
|
@@ -0,0 +1,279 @@
|
|
|
1
|
+
import { NextConfig } from 'next';
|
|
2
|
+
import { ExecOptions, SpawnOptions, ForkOptions } from 'child_process';
|
|
3
|
+
import { TsConfigJson, PackageJson } from './types.js';
|
|
4
|
+
|
|
5
|
+
declare const logLevels: readonly ["trace", "verbose", "debug", "log", "info", "warn", "error"];
|
|
6
|
+
type LogLevel = (typeof logLevels)[number];
|
|
7
|
+
declare class Logger {
|
|
8
|
+
#private;
|
|
9
|
+
static level: LogLevel;
|
|
10
|
+
static setLevel(level: LogLevel): void;
|
|
11
|
+
name?: string;
|
|
12
|
+
constructor(name?: string);
|
|
13
|
+
trace(msg: string, context?: string): void;
|
|
14
|
+
verbose(msg: string, context?: string): void;
|
|
15
|
+
debug(msg: string, context?: string): void;
|
|
16
|
+
log(msg: string, context?: string): void;
|
|
17
|
+
info(msg: string, context?: string): void;
|
|
18
|
+
warn(msg: string, context?: string): void;
|
|
19
|
+
error(msg: string, context?: string): void;
|
|
20
|
+
raw(msg: string, method?: "console" | "process"): void;
|
|
21
|
+
rawLog(msg: string, method?: "console" | "process"): void;
|
|
22
|
+
static trace(msg: string, context?: string): void;
|
|
23
|
+
static verbose(msg: string, context?: string): void;
|
|
24
|
+
static debug(msg: string, context?: string): void;
|
|
25
|
+
static log(msg: string, context?: string): void;
|
|
26
|
+
static info(msg: string, context?: string): void;
|
|
27
|
+
static warn(msg: string, context?: string): void;
|
|
28
|
+
static error(msg: string, context?: string): void;
|
|
29
|
+
static rawLog(msg: string, method?: "console" | "process"): void;
|
|
30
|
+
static raw(msg: string, method?: "console" | "process"): void;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
type Arch = "amd64" | "arm64";
|
|
34
|
+
type ExplicitDependencies = string[] | {
|
|
35
|
+
[key in Arch]: string[];
|
|
36
|
+
};
|
|
37
|
+
interface AppConfigResult {
|
|
38
|
+
rootLib?: string;
|
|
39
|
+
libs: string[];
|
|
40
|
+
backend: {
|
|
41
|
+
dockerfile: string;
|
|
42
|
+
explicitDependencies: ExplicitDependencies;
|
|
43
|
+
};
|
|
44
|
+
frontend: {
|
|
45
|
+
dockerfile: string;
|
|
46
|
+
nextConfig: NextConfig | (() => Promise<NextConfig> | NextConfig);
|
|
47
|
+
routes?: {
|
|
48
|
+
basePath?: string;
|
|
49
|
+
domains: {
|
|
50
|
+
main?: string[];
|
|
51
|
+
develop?: string[];
|
|
52
|
+
debug?: string[];
|
|
53
|
+
};
|
|
54
|
+
}[];
|
|
55
|
+
explicitDependencies: ExplicitDependencies;
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
interface LibConfigResult {
|
|
59
|
+
rootLib?: string;
|
|
60
|
+
libs: string[];
|
|
61
|
+
backend: {
|
|
62
|
+
explicitDependencies: ExplicitDependencies;
|
|
63
|
+
};
|
|
64
|
+
frontend: {
|
|
65
|
+
explicitDependencies: ExplicitDependencies;
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
interface FileConventionScanResult {
|
|
69
|
+
constants: {
|
|
70
|
+
databases: string[];
|
|
71
|
+
scalars: string[];
|
|
72
|
+
};
|
|
73
|
+
dictionary: {
|
|
74
|
+
databases: string[];
|
|
75
|
+
services: string[];
|
|
76
|
+
scalars: string[];
|
|
77
|
+
};
|
|
78
|
+
documents: {
|
|
79
|
+
databases: string[];
|
|
80
|
+
scalars: string[];
|
|
81
|
+
};
|
|
82
|
+
services: {
|
|
83
|
+
databases: string[];
|
|
84
|
+
services: string[];
|
|
85
|
+
scalars: string[];
|
|
86
|
+
};
|
|
87
|
+
signal: {
|
|
88
|
+
databases: string[];
|
|
89
|
+
services: string[];
|
|
90
|
+
scalars: string[];
|
|
91
|
+
};
|
|
92
|
+
store: {
|
|
93
|
+
databases: string[];
|
|
94
|
+
services: string[];
|
|
95
|
+
scalars: string[];
|
|
96
|
+
};
|
|
97
|
+
components: {
|
|
98
|
+
databases: string[];
|
|
99
|
+
services: string[];
|
|
100
|
+
scalars: string[];
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
interface AppScanResult {
|
|
104
|
+
name: string;
|
|
105
|
+
type: "app" | "lib";
|
|
106
|
+
akanConfig: AppConfigResult;
|
|
107
|
+
files: FileConventionScanResult;
|
|
108
|
+
libDeps: string[];
|
|
109
|
+
pkgDeps: string[];
|
|
110
|
+
dependencies: string[];
|
|
111
|
+
libs: {
|
|
112
|
+
[key: string]: LibScanResult;
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
interface LibScanResult {
|
|
116
|
+
name: string;
|
|
117
|
+
type: "app" | "lib";
|
|
118
|
+
akanConfig: LibConfigResult;
|
|
119
|
+
files: FileConventionScanResult;
|
|
120
|
+
libDeps: string[];
|
|
121
|
+
pkgDeps: string[];
|
|
122
|
+
dependencies: string[];
|
|
123
|
+
libs: {
|
|
124
|
+
[key: string]: LibScanResult;
|
|
125
|
+
};
|
|
126
|
+
}
|
|
127
|
+
interface PkgScanResult {
|
|
128
|
+
name: string;
|
|
129
|
+
pkgDeps: string[];
|
|
130
|
+
dependencies: string[];
|
|
131
|
+
}
|
|
132
|
+
interface WorkspaceScanResult {
|
|
133
|
+
appNames: string[];
|
|
134
|
+
libNames: string[];
|
|
135
|
+
pkgNames: string[];
|
|
136
|
+
apps: {
|
|
137
|
+
[key: string]: AppScanResult;
|
|
138
|
+
};
|
|
139
|
+
libs: {
|
|
140
|
+
[key: string]: LibScanResult;
|
|
141
|
+
};
|
|
142
|
+
pkgs: {
|
|
143
|
+
[key: string]: PkgScanResult;
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
declare class Executor {
|
|
148
|
+
#private;
|
|
149
|
+
logger: Logger;
|
|
150
|
+
cwdPath: string;
|
|
151
|
+
constructor(name: string, cwdPath: string);
|
|
152
|
+
exec(command: string, options?: ExecOptions): Promise<unknown>;
|
|
153
|
+
spawn(command: string, args?: string[], options?: SpawnOptions): Promise<{
|
|
154
|
+
code: number | null;
|
|
155
|
+
signal: string | null;
|
|
156
|
+
}>;
|
|
157
|
+
fork(modulePath: string, args?: string[], options?: ForkOptions): Promise<unknown>;
|
|
158
|
+
mkdir(dirPath: string): this;
|
|
159
|
+
writeFile(filePath: string, content: string | object): this;
|
|
160
|
+
writeJson(filePath: string, content: object): this;
|
|
161
|
+
readFile(filePath: string): string;
|
|
162
|
+
readJson(filePath: string): object;
|
|
163
|
+
cp(srcPath: string, destPath: string): Promise<void>;
|
|
164
|
+
log(msg: string): this;
|
|
165
|
+
verbose(msg: string): this;
|
|
166
|
+
getTsConfig(pathname: string): TsConfigJson;
|
|
167
|
+
applyTemplate({ basePath, template, scanResult, dict, }: {
|
|
168
|
+
basePath: string;
|
|
169
|
+
template: string;
|
|
170
|
+
scanResult?: AppScanResult | LibScanResult | null;
|
|
171
|
+
dict?: {
|
|
172
|
+
[key: string]: string;
|
|
173
|
+
};
|
|
174
|
+
}): Promise<void>;
|
|
175
|
+
}
|
|
176
|
+
interface ExecutorOptions {
|
|
177
|
+
workspaceRoot: string;
|
|
178
|
+
repoName: string;
|
|
179
|
+
}
|
|
180
|
+
declare class WorkspaceExecutor extends Executor {
|
|
181
|
+
#private;
|
|
182
|
+
workspaceRoot: string;
|
|
183
|
+
repoName: string;
|
|
184
|
+
constructor({ workspaceRoot, repoName }: ExecutorOptions);
|
|
185
|
+
static fromRoot(): WorkspaceExecutor;
|
|
186
|
+
scan(): Promise<WorkspaceScanResult>;
|
|
187
|
+
getApps(): Promise<string[]>;
|
|
188
|
+
getLibs(): Promise<string[]>;
|
|
189
|
+
getSyss(): Promise<[string[], string[]]>;
|
|
190
|
+
getPkgs(): Promise<string[]>;
|
|
191
|
+
}
|
|
192
|
+
interface SysExecutorOptions {
|
|
193
|
+
workspace?: WorkspaceExecutor;
|
|
194
|
+
name: string;
|
|
195
|
+
type: "app" | "lib";
|
|
196
|
+
}
|
|
197
|
+
declare class SysExecutor extends Executor {
|
|
198
|
+
workspace: WorkspaceExecutor;
|
|
199
|
+
name: string;
|
|
200
|
+
type: "app" | "lib";
|
|
201
|
+
constructor({ workspace, name, type }: SysExecutorOptions);
|
|
202
|
+
getConfig(command?: string): Promise<LibConfigResult>;
|
|
203
|
+
scan({ tsconfig, akanConfig, }: {
|
|
204
|
+
tsconfig?: TsConfigJson;
|
|
205
|
+
akanConfig: AppConfigResult | LibConfigResult;
|
|
206
|
+
}, libScanResults?: {
|
|
207
|
+
[key: string]: LibScanResult;
|
|
208
|
+
}): Promise<AppScanResult | LibScanResult>;
|
|
209
|
+
getDatabaseModules(): Promise<string[]>;
|
|
210
|
+
getServiceModules(): Promise<string[]>;
|
|
211
|
+
getScalarModules(): Promise<string[]>;
|
|
212
|
+
}
|
|
213
|
+
interface AppExecutorOptions {
|
|
214
|
+
workspace?: WorkspaceExecutor;
|
|
215
|
+
name: string;
|
|
216
|
+
}
|
|
217
|
+
declare class AppExecutor extends SysExecutor {
|
|
218
|
+
constructor({ workspace, name }: AppExecutorOptions);
|
|
219
|
+
static from(executor: SysExecutor | WorkspaceExecutor, name: string): AppExecutor;
|
|
220
|
+
getConfig(command?: string): Promise<AppConfigResult>;
|
|
221
|
+
syncAssets(libDeps: string[]): Promise<void>;
|
|
222
|
+
}
|
|
223
|
+
interface DistAppExecutorOptions {
|
|
224
|
+
workspace: WorkspaceExecutor;
|
|
225
|
+
name: string;
|
|
226
|
+
}
|
|
227
|
+
declare class DistAppExecutor extends Executor {
|
|
228
|
+
name: string;
|
|
229
|
+
constructor({ workspace, name }: DistAppExecutorOptions);
|
|
230
|
+
static from(executor: SysExecutor | WorkspaceExecutor, name: string): DistAppExecutor;
|
|
231
|
+
}
|
|
232
|
+
interface LibExecutorOptions {
|
|
233
|
+
workspace?: WorkspaceExecutor;
|
|
234
|
+
name: string;
|
|
235
|
+
}
|
|
236
|
+
declare class LibExecutor extends SysExecutor {
|
|
237
|
+
workspaceRoot: string;
|
|
238
|
+
repoName: string;
|
|
239
|
+
constructor({ workspace, name }: LibExecutorOptions);
|
|
240
|
+
static from(executor: SysExecutor | WorkspaceExecutor, name: string): LibExecutor;
|
|
241
|
+
getConfig(command?: string): Promise<LibConfigResult>;
|
|
242
|
+
}
|
|
243
|
+
interface DistLibExecutorOptions {
|
|
244
|
+
workspace: WorkspaceExecutor;
|
|
245
|
+
name: string;
|
|
246
|
+
}
|
|
247
|
+
declare class DistLibExecutor extends Executor {
|
|
248
|
+
name: string;
|
|
249
|
+
constructor({ workspace, name }: DistLibExecutorOptions);
|
|
250
|
+
static from(executor: SysExecutor | WorkspaceExecutor, name: string): DistAppExecutor | DistLibExecutor;
|
|
251
|
+
}
|
|
252
|
+
interface PkgExecutorOptions {
|
|
253
|
+
workspace?: WorkspaceExecutor;
|
|
254
|
+
name: string;
|
|
255
|
+
}
|
|
256
|
+
declare class PkgExecutor extends Executor {
|
|
257
|
+
workspace: WorkspaceExecutor;
|
|
258
|
+
name: string;
|
|
259
|
+
constructor({ workspace, name }: PkgExecutorOptions);
|
|
260
|
+
static from(executor: SysExecutor | WorkspaceExecutor, name: string): PkgExecutor;
|
|
261
|
+
scan({ packageJson, tsconfig, }?: {
|
|
262
|
+
packageJson?: PackageJson;
|
|
263
|
+
tsconfig?: TsConfigJson;
|
|
264
|
+
}): Promise<PkgScanResult>;
|
|
265
|
+
}
|
|
266
|
+
interface DistPkgExecutorOptions {
|
|
267
|
+
workspaceRoot: string;
|
|
268
|
+
repoName: string;
|
|
269
|
+
name: string;
|
|
270
|
+
}
|
|
271
|
+
declare class DistPkgExecutor extends Executor {
|
|
272
|
+
workspaceRoot: string;
|
|
273
|
+
repoName: string;
|
|
274
|
+
name: string;
|
|
275
|
+
constructor({ workspaceRoot, repoName, name }: DistPkgExecutorOptions);
|
|
276
|
+
static from(workspaceExecutor: WorkspaceExecutor, name: string): DistPkgExecutor;
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
export { AppExecutor, DistAppExecutor, DistLibExecutor, DistPkgExecutor, Executor, LibExecutor, PkgExecutor, SysExecutor, WorkspaceExecutor };
|