miniprogram-ci 2.0.8 → 2.0.10
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/CHANGELOG.md +4 -0
- package/README.md +4 -0
- package/dist/@types/ci/utils/tools.d.ts +1 -0
- package/dist/@types/common/code-analyse/index.d.ts +16 -1
- package/dist/@types/config/config.d.ts +8 -1
- package/dist/@types/index.d.ts +2 -1
- package/dist/@types/modules/corecompiler/baseCompiler.d.ts +6 -0
- package/dist/@types/modules/corecompiler/original/validate/schemaValidate.d.ts +1 -1
- package/dist/@types/modules/corecompiler/original/workerThread/task/minifywxml.d.ts +21 -25
- package/dist/@types/modules/corecompiler/originalCompiler.d.ts +1 -0
- package/dist/@types/modules/corecompiler/processHandler.d.ts +4 -3
- package/dist/@types/modules/corecompiler/summer/graph/appconf.d.ts +4 -0
- package/dist/@types/modules/corecompiler/summer/graph/appgraph.d.ts +6 -3
- package/dist/@types/modules/corecompiler/summer/graph/basegraph.d.ts +13 -3
- package/dist/@types/modules/corecompiler/summer/graph/gamegraph.d.ts +6 -3
- package/dist/@types/modules/corecompiler/summer/graph/gameplugingraph.d.ts +5 -4
- package/dist/@types/modules/corecompiler/summer/graph/plugingraph.d.ts +5 -4
- package/dist/@types/modules/corecompiler/summer/module.d.ts +20 -14
- package/dist/@types/modules/corecompiler/summer/plugins/base/javascript.d.ts +1 -1
- package/dist/@types/modules/corecompiler/summer/plugins/base/swc.d.ts +1 -1
- package/dist/@types/modules/corecompiler/summer/summer.d.ts +5 -1
- package/dist/@types/modules/corecompiler/summerCompiler.d.ts +16 -5
- package/dist/@types/modules/createSummer.d.ts +3 -2
- package/dist/@types/modules/index.d.ts +6 -0
- package/dist/@types/modules/nativecompiler/index.d.ts +1 -0
- package/dist/@types/modules/nativecompiler/ios/buildCloud.d.ts +9 -2
- package/dist/@types/modules/nativecompiler/ios/index.d.ts +2 -0
- package/dist/@types/modules/nativecompiler/nativeCompiler.d.ts +3 -0
- package/dist/@types/schema/@types/appjson.d.ts +215 -0
- package/dist/@types/schema/@types/extjson.d.ts +82 -0
- package/dist/@types/schema/@types/gamejson.d.ts +55 -0
- package/dist/@types/schema/@types/pagejson.d.ts +47 -0
- package/dist/@types/schema/@types/pluginjson.d.ts +17 -0
- package/dist/@types/schema/@types/pluginpagejson.d.ts +5 -0
- package/dist/@types/schema/@types/projectconfigjson.d.ts +194 -0
- package/dist/@types/schema/@types/projectprivateconfigjson.d.ts +114 -0
- package/dist/@types/schema/@types/sitemapjson.d.ts +10 -0
- package/dist/@types/schema/@types/themejson.d.ts +8 -0
- package/dist/@types/schema/src/index.d.ts +60 -0
- package/dist/@types/types/ci.d.ts +2 -1
- package/dist/@types/types/core.d.ts +22 -3
- package/dist/@types/types/devtools.d.ts +18 -6
- package/dist/@types/types/miniapp/index.d.ts +5 -0
- package/dist/@types/types/miniprogram-json/app.d.ts +16 -6
- package/dist/@types/types/summer.d.ts +1 -0
- package/dist/@types/utils/locales/locales.d.ts +5 -0
- package/dist/@types/utils/locales/zh.d.ts +5 -0
- package/dist/@types/utils/messageHub.d.ts +1 -1
- package/dist/@types/utils/miniapp-builder.d.ts +6 -1
- package/dist/@types/utils/packOptionsHelper.d.ts +15 -2
- package/dist/@types/utils/progressRecorder.d.ts +1 -1
- package/dist/@types/utils/tools.d.ts +5 -0
- package/dist/@types/utils/usbProcess.d.ts +3 -0
- package/dist/ci/utils/filterUnusedFile.js +1 -1
- package/dist/ci/utils/tools.js +1 -1
- package/dist/common/code-analyse/index.js +1 -1
- package/dist/config/config.js +1 -1
- package/dist/index.js +1 -1
- package/dist/modules/corecompiler/baseCompiler.js +1 -1
- package/dist/modules/corecompiler/original/compile/common.js +1 -1
- package/dist/modules/corecompiler/original/workerThread/task/compilejs.js +1 -1
- package/dist/modules/corecompiler/original/workerThread/task/index.js +1 -1
- package/dist/modules/corecompiler/original/workerThread/task/minifywxml.js +1 -1
- package/dist/modules/corecompiler/originalCompiler.js +1 -1
- package/dist/modules/corecompiler/processHandler.js +1 -1
- package/dist/modules/corecompiler/summer/graph/appconf.js +1 -1
- package/dist/modules/corecompiler/summer/graph/appgraph.js +1 -1
- package/dist/modules/corecompiler/summer/graph/basegraph.js +1 -1
- package/dist/modules/corecompiler/summer/graph/gamegraph.js +1 -1
- package/dist/modules/corecompiler/summer/graph/gameplugingraph.js +1 -1
- package/dist/modules/corecompiler/summer/graph/plugingraph.js +1 -1
- package/dist/modules/corecompiler/summer/module.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/base/es6module.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/base/javascript.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/base/swc.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/base/wxss.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/enhance.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/less.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/minifywxml.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/sass.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/terser.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/typescript.js +1 -1
- package/dist/modules/corecompiler/summer/plugins/worklet.js +1 -1
- package/dist/modules/corecompiler/summer/summer.js +1 -1
- package/dist/modules/corecompiler/summerCompiler.js +1 -1
- package/dist/modules/createSummer.js +1 -1
- package/dist/modules/index.js +1 -1
- package/dist/modules/nativecompiler/index.js +1 -1
- package/dist/modules/nativecompiler/ios/buildCloud.js +1 -1
- package/dist/modules/nativecompiler/ios/index.js +1 -1
- package/dist/modules/nativecompiler/nativeCompiler.js +1 -1
- package/dist/modules/nativecompiler/nativeEntryProcess.js +1 -1
- package/dist/project/advance/precompileProject.js +1 -1
- package/dist/project/baseProject.js +1 -1
- package/dist/schema/@types/appjson.js +1 -0
- package/dist/schema/@types/extjson.js +1 -0
- package/dist/schema/@types/gamejson.js +1 -0
- package/dist/schema/@types/pagejson.js +1 -0
- package/dist/schema/@types/pluginjson.js +1 -0
- package/dist/schema/@types/pluginpagejson.js +1 -0
- package/dist/schema/@types/projectconfigjson.js +1 -0
- package/dist/schema/@types/projectprivateconfigjson.js +1 -0
- package/dist/schema/@types/sitemapjson.js +1 -0
- package/dist/schema/@types/themejson.js +1 -0
- package/dist/schema/dist/app.js +1 -1
- package/dist/schema/dist/ext.js +1 -1
- package/dist/schema/dist/game.js +1 -1
- package/dist/schema/dist/page.js +1 -1
- package/dist/schema/dist/plugin.js +1 -1
- package/dist/schema/dist/pluginpage.js +1 -1
- package/dist/schema/dist/projectconfig.js +37 -1
- package/dist/schema/dist/projectprivateconfig.js +1 -1
- package/dist/schema/dist/sitemap.js +1 -1
- package/dist/schema/dist/theme.js +1 -1
- package/dist/schema/src/index.js +1 -0
- package/dist/utils/codesign.js +1 -1
- package/dist/utils/locales/en.js +1 -1
- package/dist/utils/locales/zh.js +1 -1
- package/dist/utils/miniapp-builder.js +1 -1
- package/dist/utils/miniappJson.js +1 -1
- package/dist/utils/packOptionsHelper.js +1 -1
- package/dist/utils/progressRecorder.js +1 -1
- package/dist/utils/subprocess/processManager.js +1 -1
- package/dist/utils/tools.js +1 -1
- package/dist/utils/usbProcess.js +1 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { MiniProgramCI, MiniProgramDevtools } from '../../types';
|
|
2
|
+
export declare const CompileSettingsKeysInProjectConfig: string[];
|
|
2
3
|
export declare function isGameApp(project: MiniProgramCI.IProject): boolean;
|
|
3
4
|
export declare const checkIsUseCompilerPlugins: (project: MiniProgramCI.IProject) => boolean | undefined;
|
|
4
5
|
export declare function isUndefined(value: any): boolean;
|
|
@@ -32,8 +32,17 @@ export declare class Analyzer {
|
|
|
32
32
|
/** 文件是否已经发生改变? */
|
|
33
33
|
invalid: boolean;
|
|
34
34
|
constructor(option: AnalyzerOption);
|
|
35
|
+
destroy(): void;
|
|
35
36
|
private getEntryDep;
|
|
36
|
-
analyse(): Promise<void>;
|
|
37
|
+
analyse(force?: boolean): Promise<void>;
|
|
38
|
+
/**
|
|
39
|
+
* 不管怎么样都会从新分析的
|
|
40
|
+
*/
|
|
41
|
+
private realAnalyse;
|
|
42
|
+
/**
|
|
43
|
+
* 只要 fileUtils 抛出 change 事件,就分析
|
|
44
|
+
* @param callback
|
|
45
|
+
*/
|
|
37
46
|
watch(callback: () => void): void;
|
|
38
47
|
serialize(): IAnalyseResult | undefined;
|
|
39
48
|
callPlugin<T extends Exclude<keyof AnalyzerPlugin, 'name'>>(event: T, ...args: any): void;
|
|
@@ -82,9 +91,11 @@ export declare class FileHelper implements IFileHelper {
|
|
|
82
91
|
root: string;
|
|
83
92
|
type: CompileType;
|
|
84
93
|
compilerPlugins: ICompilerPlugin[];
|
|
94
|
+
private _watcher;
|
|
85
95
|
dirSet: Set<string>;
|
|
86
96
|
fileSet: Set<string>;
|
|
87
97
|
constructor(root: string, type?: CompileType, compilerPlugins?: ICompilerPlugin[]);
|
|
98
|
+
destroy(): void;
|
|
88
99
|
private cacheDirName;
|
|
89
100
|
get pattern(): string;
|
|
90
101
|
init(): void;
|
|
@@ -203,6 +214,9 @@ declare interface IAppJSON {
|
|
|
203
214
|
tabBar?: {
|
|
204
215
|
custom?: boolean;
|
|
205
216
|
};
|
|
217
|
+
appBar?: {
|
|
218
|
+
custom?: boolean;
|
|
219
|
+
};
|
|
206
220
|
resolveAlias?: {
|
|
207
221
|
[key: string]: string;
|
|
208
222
|
};
|
|
@@ -260,6 +274,7 @@ export declare interface IFileHelper {
|
|
|
260
274
|
readdir(dirPath: string): Promise<string[]>;
|
|
261
275
|
watchFileChange(callback: () => void): void;
|
|
262
276
|
getLocalFileString?(filePath: string): Promise<string>;
|
|
277
|
+
destroy(): void;
|
|
263
278
|
}
|
|
264
279
|
|
|
265
280
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IProject } from '../types';
|
|
2
|
-
export declare const CI_VERSION = "2.0.
|
|
2
|
+
export declare const CI_VERSION = "2.0.10";
|
|
3
3
|
export declare const PARAM_ERROR = 10000;
|
|
4
4
|
export declare const WXML_NOT_FOUND = 10007;
|
|
5
5
|
export declare const JS_NOT_FOUND = 10008;
|
|
@@ -91,3 +91,10 @@ export declare enum AstType {
|
|
|
91
91
|
Babel = "babel",
|
|
92
92
|
Acorn = "acorn"
|
|
93
93
|
}
|
|
94
|
+
export declare enum EFilterCode {
|
|
95
|
+
Include = 0,
|
|
96
|
+
PackOptionsIgnore = 1,
|
|
97
|
+
AnalyseNoUse = 2,
|
|
98
|
+
PartialCompileNoUse = 3
|
|
99
|
+
}
|
|
100
|
+
export declare const MAX_CODE_LENGTH: number;
|
package/dist/@types/index.d.ts
CHANGED
|
@@ -18,10 +18,11 @@ import { getHelperOutputPath, getHelperDeps, isValidHelperFunc, getHelperContent
|
|
|
18
18
|
import * as adroidDeviceUtils from './modules/nativecompiler/android/device';
|
|
19
19
|
import * as iosDeviceUtils from './modules/nativecompiler/ios/device';
|
|
20
20
|
import * as miniappBuilder from './utils/miniapp-builder';
|
|
21
|
+
import packOptionsHelper from './utils/packOptionsHelper';
|
|
21
22
|
export { BaseProject, CIProject as Project, CIProject, DevtoolsProject, WebProject, PreCompileProject, };
|
|
22
23
|
export { BaseCoreCompiler, OriginalCompiler, SummerCompiler, ICompilerStatus, ICompileOptions, Builder, };
|
|
23
24
|
export * from './modules/corecompiler/original';
|
|
24
25
|
export declare const workletVersion: any;
|
|
25
|
-
export { getWhiteExtList, proxy, locales, isHexColor, DefaultProjectAttr, JSON_CONTENT_ERR, compileTypeConfig, generateMD5, mkdirSync, normalizePath, checkIsInSubPackage, getHelperOutputPath, isValidHelperFunc, getHelperName, getHelperContent, getHelperDeps, getBabelHelperVersion, getBabelHelperDepMap, escapeQuot, escapeScript, getSummerPluginConfig, };
|
|
26
|
+
export { getWhiteExtList, proxy, locales, isHexColor, DefaultProjectAttr, JSON_CONTENT_ERR, compileTypeConfig, generateMD5, mkdirSync, normalizePath, checkIsInSubPackage, getHelperOutputPath, isValidHelperFunc, getHelperName, getHelperContent, getHelperDeps, getBabelHelperVersion, getBabelHelperDepMap, escapeQuot, escapeScript, getSummerPluginConfig, packOptionsHelper, };
|
|
26
27
|
export { adroidDeviceUtils, iosDeviceUtils, miniappBuilder, };
|
|
27
28
|
export * from './ci/index';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { ExtJSON, AppJSON, IGameJSON, MiniProgramCore, PageJSON, PluginJSON, SiteMapJSON, ThemeJSON, MiniProgramDevtools } from '../../types';
|
|
3
3
|
import { SingletonTask } from '../../utils/singletontask';
|
|
4
|
+
import { EFilterCode } from '../../config/config';
|
|
4
5
|
import { FileInfo } from './summer/graph/basegraph';
|
|
5
6
|
export type ICompileOptions = MiniProgramCore.ICompileOptions;
|
|
6
7
|
export declare abstract class BaseCoreCompiler {
|
|
@@ -52,6 +53,10 @@ export declare abstract class BaseCoreCompiler {
|
|
|
52
53
|
getMPJSFileList(filter?: string): string[];
|
|
53
54
|
getMPWXSSFileList(filter?: string): string[];
|
|
54
55
|
getMPJSONFileList(filter?: string): string[];
|
|
56
|
+
getFiltedFileListReason(resultType: MiniProgramCore.IResultType): Promise<{
|
|
57
|
+
file: string;
|
|
58
|
+
code: EFilterCode;
|
|
59
|
+
}[]>;
|
|
55
60
|
getPluginFileList(prefix?: string, extName?: string): string[];
|
|
56
61
|
getPluginWXMLFileList(filter?: string): string[];
|
|
57
62
|
getPluginWXSFileList(filter?: string): string[];
|
|
@@ -61,6 +66,7 @@ export declare abstract class BaseCoreCompiler {
|
|
|
61
66
|
isValidComponent(prefix: string | undefined, filePath: string): boolean;
|
|
62
67
|
getAllFileInfo(prefix?: string): MiniProgramCore.IFileInfos;
|
|
63
68
|
abstract getMPFileInfo(): Promise<MiniProgramCore.IFileInfos>;
|
|
69
|
+
abstract getPackageWxssFileList(packagePath: string): Promise<string[]>;
|
|
64
70
|
abstract getPackageWxssFiles(packagePath: string): Promise<{
|
|
65
71
|
wxssFiles: string[];
|
|
66
72
|
content: Record<string, string>;
|
|
@@ -1,32 +1,34 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
import { MiniProgramDevtools } from '../../../../../types';
|
|
3
2
|
interface ICompileData {
|
|
4
|
-
|
|
5
|
-
root: string;
|
|
3
|
+
code: string | Buffer;
|
|
6
4
|
filePath: string;
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
root?: string;
|
|
6
|
+
setting?: IMinifySetting;
|
|
9
7
|
}
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
OTHERS = 3
|
|
8
|
+
export interface IMinifySetting {
|
|
9
|
+
collapseWhitespace?: boolean;
|
|
10
|
+
conservativeCollapse?: boolean;
|
|
11
|
+
preserveLineBreaks?: boolean;
|
|
15
12
|
}
|
|
16
|
-
declare class
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
13
|
+
export declare class TemplateTokenizer {
|
|
14
|
+
private tokens?;
|
|
15
|
+
constructor(src: string, path: string);
|
|
16
|
+
toString(): string;
|
|
17
|
+
private generateTokens;
|
|
18
|
+
private m_pSrc;
|
|
19
|
+
private path;
|
|
20
|
+
private machine;
|
|
20
21
|
}
|
|
21
|
-
declare class
|
|
22
|
+
export declare class StyleAttrValueTokenizer {
|
|
23
|
+
private tokens?;
|
|
22
24
|
constructor(src: string, path: string);
|
|
23
|
-
|
|
25
|
+
toString(): string;
|
|
26
|
+
private generateTokens;
|
|
24
27
|
private m_pSrc;
|
|
25
28
|
private path;
|
|
26
29
|
private machine;
|
|
27
30
|
}
|
|
28
|
-
declare function
|
|
29
|
-
declare function minifyWXML(data: ICompileData): Promise<{
|
|
31
|
+
export declare function minifyWXML(data: ICompileData): Promise<{
|
|
30
32
|
error: null;
|
|
31
33
|
code: string;
|
|
32
34
|
} | {
|
|
@@ -37,10 +39,4 @@ declare function minifyWXML(data: ICompileData): Promise<{
|
|
|
37
39
|
};
|
|
38
40
|
code?: undefined;
|
|
39
41
|
}>;
|
|
40
|
-
|
|
41
|
-
minifyWXML: typeof minifyWXML;
|
|
42
|
-
Tokenizer: typeof Tokenizer;
|
|
43
|
-
generateWXMLFromTokens: typeof generateWXMLFromTokens;
|
|
44
|
-
Token: typeof Token;
|
|
45
|
-
};
|
|
46
|
-
export = _default;
|
|
42
|
+
export {};
|
|
@@ -63,6 +63,7 @@ export declare class OriginalCompiler extends BaseCoreCompiler {
|
|
|
63
63
|
}>;
|
|
64
64
|
setLocale(locale: string): void;
|
|
65
65
|
clearCache(): void;
|
|
66
|
+
getPackageWxssFileList(_packagePath: string): Promise<never[]>;
|
|
66
67
|
getPackageWxssFiles(_packagePath: string): Promise<{
|
|
67
68
|
wxssFiles: string[];
|
|
68
69
|
content: Record<string, string>;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { MiniProgramDevtools } from '../../types';
|
|
2
2
|
interface IProcessMsg {
|
|
3
3
|
type: 'progress';
|
|
4
|
-
id: number;
|
|
4
|
+
id: number | string;
|
|
5
5
|
taskId: number;
|
|
6
6
|
status: string;
|
|
7
7
|
message: string;
|
|
8
8
|
}
|
|
9
9
|
interface IResponseMsg {
|
|
10
10
|
type: 'response';
|
|
11
|
-
id: number;
|
|
11
|
+
id: number | string;
|
|
12
12
|
data: any;
|
|
13
13
|
error?: {
|
|
14
14
|
code: number;
|
|
@@ -19,5 +19,6 @@ interface IResponseMsg {
|
|
|
19
19
|
}
|
|
20
20
|
type ICallbackMsg = IProcessMsg | IResponseMsg;
|
|
21
21
|
export declare function initHandler(message: MiniProgramDevtools.InitMsg): Promise<void>;
|
|
22
|
-
export declare function
|
|
22
|
+
export declare function destroy(): Promise<void>;
|
|
23
|
+
export declare function messageHandler(message: MiniProgramDevtools.SummerProcessMessage, onProgressUpdate?: MiniProgramDevtools.ProgressUpdate): Promise<ICallbackMsg | undefined>;
|
|
23
24
|
export {};
|
|
@@ -26,6 +26,10 @@ export declare class AppConf extends MiniProgramBaseConf {
|
|
|
26
26
|
pageResults: Record<string, string>;
|
|
27
27
|
componentResults: Record<string, string>;
|
|
28
28
|
}>;
|
|
29
|
+
buildPagesAndCompsWithFileListForUpload(recorder: Recorder, fileList: string[], disabelSpreadingUsingComponent?: boolean): Promise<{
|
|
30
|
+
pageResults: Record<string, string>;
|
|
31
|
+
componentResults: Record<string, string>;
|
|
32
|
+
}>;
|
|
29
33
|
onFileChange: (type: 'unlink' | 'unlinkDir' | 'add' | 'addDir' | 'change', path: string) => void;
|
|
30
34
|
protected resetState(): Promise<void>;
|
|
31
35
|
protected load(recorder: Recorder): Promise<void>;
|
|
@@ -10,9 +10,6 @@ export declare class AppGraph extends BaseGraph {
|
|
|
10
10
|
getConf(recorder: Recorder): Promise<MiniProgramDevtools.IAppConf>;
|
|
11
11
|
compileSingleCode(filePath: string, sourceCode?: string): Promise<MiniProgramDevtools.CodeFile>;
|
|
12
12
|
getDevCode(recorder: Recorder, options: MiniProgramDevtools.IPackageCodeOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
13
|
-
getDevCodeByFileList(recorder: Recorder, options: {
|
|
14
|
-
fileList: string[];
|
|
15
|
-
}): Promise<MiniProgramDevtools.CodeFiles>;
|
|
16
13
|
getProdCode(recorder: Recorder, options: MiniProgramDevtools.IPackageCodeOptions & MiniProgramCore.ICompileOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
17
14
|
protected getLocalCodeFileList(): string[];
|
|
18
15
|
protected onFileChangeForGraph(type: 'unlink' | 'unlinkDir' | 'add' | 'addDir' | 'change', path: string): void;
|
|
@@ -24,4 +21,10 @@ export declare class AppGraph extends BaseGraph {
|
|
|
24
21
|
[x: string]: string;
|
|
25
22
|
};
|
|
26
23
|
}>;
|
|
24
|
+
protected compileJSONWithFileList(options: MiniProgramCore.ICompileOptionsWithFileList, recorder: Recorder): Promise<{
|
|
25
|
+
conf: MiniProgramDevtools.IAppConf;
|
|
26
|
+
jsons: {
|
|
27
|
+
[x: string]: string;
|
|
28
|
+
};
|
|
29
|
+
}>;
|
|
27
30
|
}
|
|
@@ -54,14 +54,14 @@ export declare abstract class BaseGraph {
|
|
|
54
54
|
protected abstract checkFilePackage(path: string): string;
|
|
55
55
|
protected abstract getIndependentRoot(targetPath: string): string;
|
|
56
56
|
private onFileChange;
|
|
57
|
-
private onFileAndDirChange;
|
|
58
57
|
private invalidateModules;
|
|
59
58
|
private loadModuleFromFile;
|
|
60
59
|
private loadSourceForModule;
|
|
61
60
|
protected doCompileSingleCode(info: FileInfo, sourceCode?: string): Promise<MiniProgramDevtools.CodeFile>;
|
|
62
61
|
private getCodeFileTask;
|
|
63
62
|
protected getCodeFiles(files: FileInfo[], recorder: Recorder, options?: MiniProgramCore.ICompileOptions & {
|
|
64
|
-
useCache
|
|
63
|
+
useCache?: boolean;
|
|
64
|
+
resultType?: MiniProgramCore.IResultType;
|
|
65
65
|
}): Promise<MiniProgramDevtools.CodeFiles>;
|
|
66
66
|
private readFile;
|
|
67
67
|
private tranform;
|
|
@@ -69,16 +69,22 @@ export declare abstract class BaseGraph {
|
|
|
69
69
|
private optimize;
|
|
70
70
|
private compress;
|
|
71
71
|
compile(options: MiniProgramCore.ICompileOptions, recorder: Recorder): Promise<MiniProgramDevtools.ICompileResult>;
|
|
72
|
+
compileWithFileList(options: MiniProgramCore.ICompileOptionsWithFileList, recorder: Recorder): Promise<MiniProgramDevtools.ICompileResult>;
|
|
72
73
|
protected abstract getWhiteListConfig(): Promise<Set<string>>;
|
|
73
74
|
getLocalFileList(): Promise<MiniProgramCore.IFileInfos>;
|
|
74
75
|
private compileOther;
|
|
75
76
|
private compileCodeWithoutJSON;
|
|
77
|
+
private compileCodeWithoutJSONWithFileList;
|
|
76
78
|
protected isBabelSettingIgnore(fileInfo: ResolveFileInfo): boolean;
|
|
77
79
|
protected abstract onFileChangeForGraph(type: 'unlink' | 'unlinkDir' | 'add' | 'addDir' | 'change', path: string): void;
|
|
78
80
|
abstract getConf(recorder: Recorder): Promise<MiniProgramDevtools.IAppConf | MiniProgramDevtools.IPluginConf | MiniProgramDevtools.IGameConf | MiniProgramDevtools.IGamePluginConf>;
|
|
79
|
-
|
|
81
|
+
getDevCodeByFileList(recorder: Recorder, options: {
|
|
80
82
|
fileList: string[];
|
|
81
83
|
}): Promise<MiniProgramDevtools.CodeFiles>;
|
|
84
|
+
getProdCodeByFileList(recorder: Recorder, options: {
|
|
85
|
+
fileList: string[];
|
|
86
|
+
resultType?: MiniProgramCore.IResultType;
|
|
87
|
+
}): Promise<MiniProgramDevtools.CodeFiles>;
|
|
82
88
|
abstract getDevCode(recorder: Recorder, options?: MiniProgramDevtools.IPackageCodeOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
83
89
|
abstract getProdCode(recorder: Recorder, options?: MiniProgramDevtools.IPackageCodeOptions & MiniProgramCore.ICompileOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
84
90
|
abstract compileSingleCode(filePath: string, sourceCode?: string): Promise<MiniProgramDevtools.CodeFile>;
|
|
@@ -86,6 +92,10 @@ export declare abstract class BaseGraph {
|
|
|
86
92
|
conf: any;
|
|
87
93
|
jsons: Record<string, string>;
|
|
88
94
|
}>;
|
|
95
|
+
protected abstract compileJSONWithFileList(options: MiniProgramCore.ICompileOptionsWithFileList, recorder: Recorder): Promise<{
|
|
96
|
+
conf: any;
|
|
97
|
+
jsons: Record<string, string>;
|
|
98
|
+
}>;
|
|
89
99
|
protected abstract getLocalCodeFileList(): string[];
|
|
90
100
|
}
|
|
91
101
|
export {};
|
|
@@ -10,9 +10,6 @@ export declare class GameGraph extends BaseGraph {
|
|
|
10
10
|
getConf(recorder: Recorder): Promise<MiniProgramDevtools.IGameConf>;
|
|
11
11
|
compileSingleCode(filePath: string, sourceCode?: string): Promise<MiniProgramDevtools.CodeFile>;
|
|
12
12
|
getDevCode(recorder: Recorder, options: MiniProgramDevtools.IPackageCodeOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
13
|
-
getDevCodeByFileList(recorder: Recorder, options: {
|
|
14
|
-
fileList: string[];
|
|
15
|
-
}): Promise<MiniProgramDevtools.CodeFiles>;
|
|
16
13
|
getProdCode(recorder: Recorder, options: MiniProgramDevtools.IPackageCodeOptions & MiniProgramCore.ICompileOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
17
14
|
protected getLocalCodeFileList(): string[];
|
|
18
15
|
protected onFileChangeForGraph(type: 'unlink' | 'unlinkDir' | 'add' | 'addDir' | 'change', path: string): void;
|
|
@@ -24,4 +21,10 @@ export declare class GameGraph extends BaseGraph {
|
|
|
24
21
|
[x: string]: string;
|
|
25
22
|
};
|
|
26
23
|
}>;
|
|
24
|
+
protected compileJSONWithFileList(options: MiniProgramCore.ICompileOptionsWithFileList, recorder: Recorder): Promise<{
|
|
25
|
+
conf: MiniProgramDevtools.IGameConf;
|
|
26
|
+
jsons: {
|
|
27
|
+
[x: string]: string;
|
|
28
|
+
};
|
|
29
|
+
}>;
|
|
27
30
|
}
|
|
@@ -10,17 +10,18 @@ export declare class GamePluginGraph extends BaseGraph {
|
|
|
10
10
|
getConf(recorder: Recorder): Promise<MiniProgramDevtools.IGamePluginConf>;
|
|
11
11
|
compileSingleCode(filePath: string, sourceCode?: string): Promise<MiniProgramDevtools.CodeFile>;
|
|
12
12
|
getDevCode(recorder: Recorder): Promise<MiniProgramDevtools.CodeFiles>;
|
|
13
|
-
getDevCodeByFileList(recorder: Recorder, options: {
|
|
14
|
-
fileList: string[];
|
|
15
|
-
}): Promise<MiniProgramDevtools.CodeFiles>;
|
|
16
13
|
getProdCode(recorder: Recorder, options: MiniProgramDevtools.IPackageCodeOptions & MiniProgramCore.ICompileOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
17
14
|
protected getLocalCodeFileList(): string[];
|
|
18
15
|
protected onFileChangeForGraph(type: 'unlink' | 'unlinkDir' | 'add' | 'addDir' | 'change', path: string): void;
|
|
19
|
-
getPackageFile(): Promise<FileInfo[]>;
|
|
16
|
+
getPackageFile(root?: string): Promise<FileInfo[]>;
|
|
20
17
|
protected checkFilePackage(path: string): string;
|
|
21
18
|
protected getIndependentRoot(targetPath: string): string;
|
|
22
19
|
protected compileJSON(): Promise<{
|
|
23
20
|
conf: MiniProgramDevtools.IGamePluginConf;
|
|
24
21
|
jsons: Record<string, string>;
|
|
25
22
|
}>;
|
|
23
|
+
protected compileJSONWithFileList(): Promise<{
|
|
24
|
+
conf: MiniProgramDevtools.IGamePluginConf;
|
|
25
|
+
jsons: Record<string, string>;
|
|
26
|
+
}>;
|
|
26
27
|
}
|
|
@@ -10,17 +10,18 @@ export declare class PluginGraph extends BaseGraph {
|
|
|
10
10
|
getConf(recorder: Recorder): Promise<MiniProgramDevtools.IPluginConf>;
|
|
11
11
|
compileSingleCode(filePath: string, sourceCode?: string): Promise<MiniProgramDevtools.CodeFile>;
|
|
12
12
|
getDevCode(recorder: Recorder): Promise<MiniProgramDevtools.CodeFiles>;
|
|
13
|
-
getDevCodeByFileList(recorder: Recorder, options: {
|
|
14
|
-
fileList: string[];
|
|
15
|
-
}): Promise<MiniProgramDevtools.CodeFiles>;
|
|
16
13
|
getProdCode(recorder: Recorder, options: MiniProgramDevtools.IPackageCodeOptions & MiniProgramCore.ICompileOptions): Promise<MiniProgramDevtools.CodeFiles>;
|
|
17
14
|
protected getLocalCodeFileList(): string[];
|
|
18
15
|
protected onFileChangeForGraph(type: 'unlink' | 'unlinkDir' | 'add' | 'addDir' | 'change', path: string): void;
|
|
19
|
-
getPackageFile(): Promise<FileInfo[]>;
|
|
16
|
+
getPackageFile(root?: string): Promise<FileInfo[]>;
|
|
20
17
|
protected getIndependentRoot(targetPath: string): string;
|
|
21
18
|
protected checkFilePackage(path: string): string;
|
|
22
19
|
protected compileJSON(): Promise<{
|
|
23
20
|
conf: MiniProgramDevtools.IPluginConf;
|
|
24
21
|
jsons: Record<string, string>;
|
|
25
22
|
}>;
|
|
23
|
+
protected compileJSONWithFileList(): Promise<{
|
|
24
|
+
conf: MiniProgramDevtools.IPluginConf;
|
|
25
|
+
jsons: Record<string, string>;
|
|
26
|
+
}>;
|
|
26
27
|
}
|
|
@@ -21,23 +21,29 @@ export default class Module {
|
|
|
21
21
|
readonly path: string;
|
|
22
22
|
readonly sourcePath: string;
|
|
23
23
|
fileType: FileType;
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
source?: MiniProgramSummer.SourceDescription;
|
|
29
|
-
target?: MiniProgramSummer.GenerateDescription;
|
|
30
|
-
processInfo?: MiniProgramSummer.IPluginProcessInfo[];
|
|
24
|
+
private _jsTag?;
|
|
25
|
+
private _error;
|
|
26
|
+
private loadResult?;
|
|
27
|
+
private generateResultPromise;
|
|
31
28
|
depFiles: string[];
|
|
32
29
|
independentRoot: string;
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
loadEnd: number;
|
|
30
|
+
isBabelIgnore: boolean;
|
|
31
|
+
private generatedTS;
|
|
36
32
|
constructor(graph: BaseGraph, path: string, sourcePath: string, fileType: FileType);
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
33
|
+
private transResultType;
|
|
34
|
+
getGeneratedTS(resultType: MiniProgramCore.IResultType): number;
|
|
35
|
+
setError(resultType: MiniProgramCore.IResultType, error: CustomError | Error): void;
|
|
36
|
+
getError(resultType: MiniProgramCore.IResultType): Error | CustomError | undefined;
|
|
37
|
+
getJsTag(): Promise<JsTag | undefined>;
|
|
38
|
+
getSource(): Promise<MiniProgramSummer.SourceDescription>;
|
|
39
|
+
getMd5(): Promise<string>;
|
|
40
|
+
setLoadingPromise(promise: Promise<MiniProgramSummer.ILoadResult>): void;
|
|
41
|
+
getLoadingPromise(): Promise<MiniProgramSummer.ILoadResult> | undefined;
|
|
42
|
+
setGeneratingPromise(resultType: MiniProgramCore.IResultType, promise: Promise<MiniProgramSummer.IGenerateResult>): void;
|
|
43
|
+
getGeneratingPromise(resultType: MiniProgramCore.IResultType): Promise<MiniProgramSummer.IGenerateResult> | undefined;
|
|
44
|
+
getProcessInfo(resultType: MiniProgramCore.IResultType): Promise<MiniProgramSummer.IPluginProcessInfo[] | undefined>;
|
|
45
|
+
toCodeFile(resultType: MiniProgramCore.IResultType): Promise<MiniProgramDevtools.CodeFile | MiniProgramDevtools.CodeError>;
|
|
46
|
+
toGenerateResult(resultType: MiniProgramCore.IResultType): Promise<MiniProgramSummer.IGenerateResult | MiniProgramDevtools.CodeError>;
|
|
41
47
|
toJSON(): MiniProgramSummer.ModuleJSON;
|
|
42
48
|
addWatchFile(file: string): void;
|
|
43
49
|
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { MiniProgramCore, MiniProgramSummer } from '../../../../../types';
|
|
2
|
-
export
|
|
2
|
+
export { MAX_CODE_LENGTH, } from '../../../../../config/config';
|
|
3
3
|
export default function (project: MiniProgramCore.IPreCompileProject): MiniProgramSummer.SummerPlugin;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MiniProgramCore, MiniProgramSummer } from '../../../../../types';
|
|
2
|
-
export
|
|
2
|
+
export { MAX_CODE_LENGTH, } from '../../../../../config/config';
|
|
3
3
|
export declare function getSWCRoot(project: MiniProgramCore.IPreCompileProject, independentRoot: string): string;
|
|
4
4
|
export default function (project: MiniProgramCore.IPreCompileProject, options: {
|
|
5
5
|
disableUseStrict: boolean;
|
|
@@ -31,11 +31,15 @@ export declare class SummerCompiler {
|
|
|
31
31
|
destroy(): void;
|
|
32
32
|
getStatus(): MiniProgramDevtools.ICompilerStatus;
|
|
33
33
|
clearCache(): void;
|
|
34
|
-
getPackageFiles({ graphId, root, }:
|
|
34
|
+
getPackageFiles({ graphId, root, }: MiniProgramCore.IGetPackageFilesOptions, recorder: Recorder): Promise<import("./graph/basegraph").FileInfo[] | undefined>;
|
|
35
35
|
getConf({ graphId }: MiniProgramDevtools.IGetConfOptions, recorder: Recorder): Promise<MiniProgramDevtools.IAppConf | MiniProgramDevtools.IPluginConf | MiniProgramDevtools.IGameConf | MiniProgramDevtools.IGamePluginConf>;
|
|
36
36
|
getCode(options: MiniProgramDevtools.IGetCodeOptions, recorder: Recorder): Promise<MiniProgramDevtools.CodeFiles>;
|
|
37
37
|
getDevCodeByFileList(options: MiniProgramDevtools.IGetCodeByFileListOptions, recorder: Recorder): Promise<MiniProgramDevtools.CodeFiles>;
|
|
38
38
|
getLocalFileList(graphId: MiniProgramDevtools.GraphId): Promise<MiniProgramCore.IFileInfos>;
|
|
39
39
|
compileSingleCode(options: MiniProgramDevtools.ICompileSingleCodeOptions, recorder: Recorder): Promise<MiniProgramDevtools.CodeFile>;
|
|
40
|
+
compileNewLogic(options: MiniProgramCore.ICompileOptionsWithFileList, recorder: Recorder): Promise<{
|
|
41
|
+
app: MiniProgramDevtools.ICompileResult;
|
|
42
|
+
plugin?: MiniProgramDevtools.ICompileResult;
|
|
43
|
+
}>;
|
|
40
44
|
compile(options: MiniProgramCore.ICompileOptions, recorder: Recorder): Promise<MiniProgramDevtools.ICompileResult>;
|
|
41
45
|
}
|
|
@@ -4,22 +4,25 @@ import { FileInfo } from './summer/graph/basegraph';
|
|
|
4
4
|
import { SubProcessProxy } from '../../utils/subprocess/processManager';
|
|
5
5
|
import { IMessageHub } from '../../utils/messageHub';
|
|
6
6
|
import { BaseCoreCompiler } from './baseCompiler';
|
|
7
|
+
import { Analyzer } from '../../common/code-analyse';
|
|
7
8
|
export { ICompilerStatus } from './summer/summer';
|
|
8
9
|
export declare class SummerCompiler extends BaseCoreCompiler {
|
|
9
10
|
project: MiniProgramCore.IPreCompileProject;
|
|
10
11
|
private cachePath;
|
|
11
12
|
private projectInfo;
|
|
12
13
|
private devtoolMessagehub;
|
|
14
|
+
private analyzer;
|
|
15
|
+
private _filterFactory?;
|
|
13
16
|
readonly isSummer = true;
|
|
14
17
|
subProcessManager: SubProcessProxy | undefined;
|
|
15
|
-
private codeCache;
|
|
16
18
|
private promiseCache;
|
|
19
|
+
private _taskCache;
|
|
17
20
|
private messageHub;
|
|
18
21
|
_status: MiniProgramDevtools.ICompilerStatus | undefined;
|
|
19
22
|
private _eventAdded;
|
|
20
23
|
private _locale;
|
|
21
|
-
private
|
|
22
|
-
constructor(project: MiniProgramCore.IPreCompileProject, cachePath: string, projectInfo: MiniProgramDevtools.IDevtoolsProjectInfo, devtoolMessagehub: IMessageHub);
|
|
24
|
+
private devCodeCacheByPath;
|
|
25
|
+
constructor(project: MiniProgramCore.IPreCompileProject, cachePath: string, projectInfo: MiniProgramDevtools.IDevtoolsProjectInfo, devtoolMessagehub: IMessageHub, analyzer: Analyzer, _filterFactory?: MiniProgramDevtools.IFilterFactory | undefined);
|
|
23
26
|
get status(): MiniProgramDevtools.ICompilerStatus | undefined;
|
|
24
27
|
protected init(): Promise<void>;
|
|
25
28
|
private loadStatus;
|
|
@@ -33,9 +36,10 @@ export declare class SummerCompiler extends BaseCoreCompiler {
|
|
|
33
36
|
private invalidCodeCache;
|
|
34
37
|
private onProgressUpdate;
|
|
35
38
|
private getConf;
|
|
36
|
-
getPackageFiles(graphId: MiniProgramDevtools.GraphId, root: string): Promise<FileInfo[]>;
|
|
39
|
+
getPackageFiles(graphId: MiniProgramDevtools.GraphId, root: string, resultType?: MiniProgramCore.IResultType, useCache?: boolean): Promise<FileInfo[]>;
|
|
40
|
+
_getPackageFiles: (graphId: import("../../types").MiniProgramCI.ProjectType, root: string, resultType?: MiniProgramCore.IResultType) => Promise<FileInfo[]>;
|
|
41
|
+
private filterFactory;
|
|
37
42
|
private getCodeByFileList;
|
|
38
|
-
private getCode;
|
|
39
43
|
getExtJSON(): Promise<ExtJSON.IExtJSON>;
|
|
40
44
|
getAppJSON(): Promise<any>;
|
|
41
45
|
getGameJSON(): Promise<any>;
|
|
@@ -57,6 +61,7 @@ export declare class SummerCompiler extends BaseCoreCompiler {
|
|
|
57
61
|
wxsFiles: string[];
|
|
58
62
|
content: Record<string, string>;
|
|
59
63
|
}>;
|
|
64
|
+
getPackageWxssFileList(packagePath: string): Promise<any[]>;
|
|
60
65
|
getPackageWxssFiles(packagePath: string): Promise<{
|
|
61
66
|
wxssFiles: string[];
|
|
62
67
|
content: Record<string, string>;
|
|
@@ -105,6 +110,8 @@ export declare class SummerCompiler extends BaseCoreCompiler {
|
|
|
105
110
|
map: string | import("../../types").MiniProgramSummer.SourceMap | undefined;
|
|
106
111
|
}>;
|
|
107
112
|
compile(options: MiniProgramCore.ICompileOptions): Promise<MiniProgramDevtools.ICompileResult>;
|
|
113
|
+
private compileOther;
|
|
114
|
+
compile2(options: MiniProgramCore.ICompileOptions): Promise<MiniProgramDevtools.ICompileResult>;
|
|
108
115
|
getPluginJSON(localPath?: string): Promise<any>;
|
|
109
116
|
getPluginPageJSON(pagePath: string): Promise<any>;
|
|
110
117
|
getPluginComponents(): Promise<string[]>;
|
|
@@ -134,4 +141,8 @@ export declare class SummerCompiler extends BaseCoreCompiler {
|
|
|
134
141
|
pages: Record<string, any>;
|
|
135
142
|
comps: Record<string, any>;
|
|
136
143
|
}>;
|
|
144
|
+
getFiltedFileListReason(resultType: MiniProgramCore.IResultType): Promise<{
|
|
145
|
+
file: string;
|
|
146
|
+
code: number;
|
|
147
|
+
}[]>;
|
|
137
148
|
}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { MiniProgramCore } from '../types';
|
|
2
2
|
import { SummerCompiler, ICompilerStatus } from './corecompiler/summerCompiler';
|
|
3
|
+
import { Analyzer } from '../common/code-analyse';
|
|
3
4
|
export declare class SummerCompilerFactory {
|
|
4
5
|
summerCompiler: SummerCompiler | null;
|
|
5
6
|
private project;
|
|
6
7
|
private createPromise;
|
|
7
8
|
summerCompilerStatus: ICompilerStatus | undefined;
|
|
8
9
|
private releaseCbs;
|
|
9
|
-
getSummerCompiler(project: MiniProgramCore.IPreCompileProject): Promise<SummerCompiler>;
|
|
10
|
+
getSummerCompiler(project: MiniProgramCore.IPreCompileProject, analyzer: Analyzer): Promise<SummerCompiler>;
|
|
10
11
|
private shouldCreate;
|
|
11
12
|
private releaseLastCompiler;
|
|
12
13
|
private ensureCacheDir;
|
|
@@ -15,4 +16,4 @@ export declare class SummerCompilerFactory {
|
|
|
15
16
|
private getSummerOptions;
|
|
16
17
|
}
|
|
17
18
|
export declare const summerCompilerFactory: SummerCompilerFactory;
|
|
18
|
-
export declare const getSummerCompiler: (project: MiniProgramCore.IPreCompileProject) => Promise<SummerCompiler>;
|
|
19
|
+
export declare const getSummerCompiler: (project: MiniProgramCore.IPreCompileProject, analyzer: Analyzer) => Promise<SummerCompiler>;
|
|
@@ -4,6 +4,7 @@ import { IMessageHub, IConsoleDisplay } from '../utils/messageHub';
|
|
|
4
4
|
import { PreCompiler } from './precompiler/index';
|
|
5
5
|
import { SummerCompiler } from './corecompiler/summerCompiler';
|
|
6
6
|
import { NativeCompiler } from './nativecompiler';
|
|
7
|
+
import { Analyzer } from '../common/code-analyse';
|
|
7
8
|
interface IBuilderOptions {
|
|
8
9
|
summerCompilerClass?: typeof SummerCompiler;
|
|
9
10
|
cachePath?: string;
|
|
@@ -15,6 +16,7 @@ interface IBuilderOptions {
|
|
|
15
16
|
targetPlatform?: MiniProgramCore.ITargetPlatform;
|
|
16
17
|
targetPlatformDefines?: MiniProgramCore.ITargetPlatformDefine;
|
|
17
18
|
outputDir?: string;
|
|
19
|
+
filterFactory?: MiniProgramDevtools.IFilterFactory;
|
|
18
20
|
}
|
|
19
21
|
export declare class Builder {
|
|
20
22
|
originProject: MiniProgramCI.IProject;
|
|
@@ -25,10 +27,14 @@ export declare class Builder {
|
|
|
25
27
|
private _options;
|
|
26
28
|
private _checkReadyTask?;
|
|
27
29
|
private _getSummerCompilerTask?;
|
|
30
|
+
private _getPrecompileProjectTask?;
|
|
28
31
|
private _originalCompiler;
|
|
32
|
+
private _analyzer?;
|
|
29
33
|
constructor(project: MiniProgramCI.IProject, opts: IBuilderOptions);
|
|
30
34
|
getCompiler(): Promise<any>;
|
|
35
|
+
getAnalyzer(): Promise<Analyzer>;
|
|
31
36
|
getPreCompileProject(): Promise<PreCompileProject>;
|
|
37
|
+
private _getPreCompileProject;
|
|
32
38
|
getPreCompiler(): Promise<PreCompiler>;
|
|
33
39
|
getSummerCompiler(): Promise<any>;
|
|
34
40
|
private _getSummerCompiler;
|
|
@@ -28,6 +28,7 @@ export declare class NativeCompiler {
|
|
|
28
28
|
buildAndroidPlugin(opts: IMiniApp.IAndroidBuildPluginArgs): Promise<void>;
|
|
29
29
|
buildIOSPlugin(opts: IMiniApp.IBuildPluginIOSFrameworkArgs): Promise<void>;
|
|
30
30
|
packIOSCloudBuildMaterial(opts: IMiniApp.IIOSBuildCloudGenMaterialArgs): Promise<string>;
|
|
31
|
+
initUSBConnectionProcess(): Promise<void>;
|
|
31
32
|
destroy(): void;
|
|
32
33
|
}
|
|
33
34
|
export {};
|
|
@@ -3,6 +3,12 @@ import { IMiniApp, MiniProgramCore } from '../../../types';
|
|
|
3
3
|
import { IEntitlements } from '../../../utils/codesign';
|
|
4
4
|
import II18NInfo = IMiniApp.II18NInfo;
|
|
5
5
|
type ITheme = 'Light' | 'LightSpecial' | 'Dark' | 'DarkSpecial' | 'Default';
|
|
6
|
+
type IOpenMimeTypes = {
|
|
7
|
+
CFBundleTypeName: string;
|
|
8
|
+
LSHandlerRank: 'Owner' | 'Default' | 'Alternate' | 'None';
|
|
9
|
+
CFBundleTypeRole: 'Editor' | 'Viewer' | 'Shell' | 'None';
|
|
10
|
+
LSItemContentTypes: string[];
|
|
11
|
+
}[];
|
|
6
12
|
export declare const remoteBuildProjectMaterialAbsoluteCacheDir = "__absoluteFile";
|
|
7
13
|
export interface IBuildCloudResult {
|
|
8
14
|
projectPath: string;
|
|
@@ -21,6 +27,7 @@ declare class buildCloudManager {
|
|
|
21
27
|
updatePrivacyBackgroundImage(projectPath: string, demoIpaPath: string, recorder: Recorder, type: 'contentViewImage' | 'cancelButtonImage' | 'confirmButtonImage', imagePath: string): void;
|
|
22
28
|
updateIOSInfoPlistInfo(projectPath: string, bindAppInfo: MiniProgramCore.IStringKeyMap, demoIpaPath: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, recorder: Recorder, i18nInfo: II18NInfo): Promise<any>;
|
|
23
29
|
getBundleIdentifier(mobileapp_info: MiniProgramCore.IStringKeyMap): any;
|
|
30
|
+
validateCFBundleDocumentTypes(openMimeTypes: IOpenMimeTypes, recorder: Recorder): boolean;
|
|
24
31
|
useGDT(iosMiniappJson: MiniProgramCore.IStringKeyMap): any;
|
|
25
32
|
updateIOSAppConfigPlistInfo(projectPath: string, bindAppInfo: MiniProgramCore.IStringKeyMap, demoIpaPath: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, sdkPath: string, isSimulator: boolean, recorder: Recorder, theme: ITheme | undefined, i18nInfo: II18NInfo): Promise<void>;
|
|
26
33
|
updateIOSAppexInfoPlistInfo(bindAppInfo: MiniProgramCore.IStringKeyMap, demoIpaPath: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, CFBundleVersion: number, recorder: Recorder): Promise<void>;
|
|
@@ -28,8 +35,8 @@ declare class buildCloudManager {
|
|
|
28
35
|
updateIOSIcons(projectPath: string, demoIpaPath: string, miniappCacheDirPath: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, isPublish: boolean, recorder: Recorder): Promise<void>;
|
|
29
36
|
replaceLaunchScreenImage(storyboardPath: string, newScreenImagePath: string, oldScreenImageName: string, recorder: Recorder, projectPath: string, demoIpaPath: string): string | undefined;
|
|
30
37
|
updateSplashScreen(projectPath: string, demoIpaPath: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, recorder: Recorder, theme: ITheme | undefined, i18nInfo: II18NInfo): Promise<void>;
|
|
31
|
-
genUseExtendedSdk(iosMiniappJson: MiniProgramCore.IStringKeyMap): MiniProgramCore.IStringKeyMap<any>;
|
|
32
|
-
updateExtendedSdk(bindAppInfo: MiniProgramCore.IStringKeyMap, demoIpaPath: string, sdkPath: string, arch: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, recorder: Recorder): Promise<void>;
|
|
38
|
+
genUseExtendedSdk(iosMiniappJson: MiniProgramCore.IStringKeyMap, debugInfo?: IMiniApp.IDebugInfo): MiniProgramCore.IStringKeyMap<any>;
|
|
39
|
+
updateExtendedSdk(bindAppInfo: MiniProgramCore.IStringKeyMap, demoIpaPath: string, sdkPath: string, arch: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, debugInfo: IMiniApp.IDebugInfo | undefined, recorder: Recorder): Promise<void>;
|
|
33
40
|
updatePrivacyInfo(demoIpaPath: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, recorder: Recorder): Promise<void>;
|
|
34
41
|
updatePlugin(demoIpaPath: string, pluginDirList: IMiniApp.IIOSPluginDir[], projectPath: string, iosMiniappJson: MiniProgramCore.IStringKeyMap, miniappCacheDirPath: string, isPublish: boolean, CFBundleVersion: string, recorder: Recorder): Promise<void>;
|
|
35
42
|
copyUserResourcePathIntoPlugins(pluginId: string, projectPath: string, configResourcePath: string, distFrameworkPath: string, recorder: Recorder): void;
|