@oipage/cli 0.2.1-alpha.0 → 0.3.0-alpha.1
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/.github/FUNDING.yml +11 -11
- package/AUTHORS.txt +6 -6
- package/CHANGELOG +33 -21
- package/LICENSE +20 -20
- package/README.md +132 -132
- package/bin/WebSocket/decodeWsFrame.js +43 -43
- package/bin/WebSocket/encodeWsFrame.js +28 -28
- package/bin/WebSocket/headersToJSON.js +26 -26
- package/bin/WebSocket/index.js +83 -83
- package/bin/data/mineTypes.json +104 -104
- package/bin/disk.js +42 -42
- package/bin/help.js +53 -50
- package/bin/intercept.js +15 -15
- package/bin/network.js +21 -21
- package/bin/notebook/index.js +9 -0
- package/bin/proxy.js +75 -75
- package/bin/run +142 -134
- package/bin/serve.js +218 -195
- package/bin/template/404.html +184 -184
- package/bin/tools/deleteEmptyFolder.js +33 -33
- package/bin/tools/format.js +75 -75
- package/bin/tools/network.js +42 -42
- package/bin/tools/openBrowser.js +25 -25
- package/bin/tools/resolve404.js +83 -83
- package/bin/tools/resolveImport.js +89 -88
- package/bin/website-htmls/components/ui-select-file/index.html +8 -8
- package/bin/website-htmls/components/ui-select-file/index.js +42 -42
- package/bin/website-htmls/components/ui-select-file/index.scss +44 -44
- package/bin/website-htmls/dialogs/imageSize/index.html +54 -54
- package/bin/website-htmls/dialogs/imageSize/index.js +53 -53
- package/bin/website-htmls/dialogs/imageSize/index.scss +140 -140
- package/bin/website-htmls/dialogs/index.js +52 -52
- package/bin/website-htmls/images/addFile.svg +1 -1
- package/bin/website-htmls/images/img-to-pdf.svg +1 -1
- package/bin/website-htmls/index.html +17 -17
- package/bin/website-htmls/main.js +13 -13
- package/bin/website-htmls/pages/App/index.html +6 -6
- package/bin/website-htmls/pages/App/index.js +22 -22
- package/bin/website-htmls/pages/App/index.scss +43 -43
- package/bin/website-htmls/pages/appStore/index.html +7 -7
- package/bin/website-htmls/pages/appStore/index.js +19 -19
- package/bin/website-htmls/pages/appStore/index.scss +54 -54
- package/bin/website-htmls/pages/chart/index.html +8 -8
- package/bin/website-htmls/pages/chart/index.js +72 -72
- package/bin/website-htmls/pages/chart/index.scss +71 -71
- package/bin/website-htmls/pages/home/index.html +19 -19
- package/bin/website-htmls/pages/home/index.js +19 -19
- package/bin/website-htmls/pages/home/index.scss +87 -87
- package/bin/website-htmls/pages/image-editor/index.html +27 -27
- package/bin/website-htmls/pages/image-editor/index.js +106 -106
- package/bin/website-htmls/pages/image-editor/index.scss +69 -69
- package/bin/website-htmls/pages/img-to-pdf/index.html +3 -3
- package/bin/website-htmls/pages/img-to-pdf/index.js +44 -44
- package/bin/website-htmls/pages/img-to-pdf/index.scss +9 -9
- package/bin/website-htmls/pages/recorder-screen/index.html +15 -15
- package/bin/website-htmls/pages/recorder-screen/index.js +227 -227
- package/bin/website-htmls/pages/recorder-screen/index.scss +52 -52
- package/bin/website-htmls/router.config.js +29 -29
- package/bin/website-htmls/styles/common.css +44 -44
- package/bin/website-htmls/styles/normalize.css +94 -94
- package/bin/website-plugins/intercept/chart.js +33 -33
- package/bin/website-plugins/intercept/getPackage.js +17 -17
- package/bin/website-plugins/intercept/head.js +8 -8
- package/bin/website-plugins/intercept/index.js +8 -8
- package/bin/website-plugins/intercept/oipage-vislite-intercept.js +55 -55
- package/bin/website-plugins/intercept/oipage-zipaper-intercept.js +36 -36
- package/bin/website-plugins/loader/index.js +11 -11
- package/bin/website-plugins/loader/oipage-html-loader.js +7 -7
- package/bin/website-plugins/loader/oipage-scss-loader.js +149 -149
- package/docs/config.md +84 -84
- package/package.json +42 -42
- package/src/index.js +28 -28
- package/types/serve.d.ts +76 -76
package/bin/serve.js
CHANGED
|
@@ -1,196 +1,219 @@
|
|
|
1
|
-
const { join } = require("path");
|
|
2
|
-
const { existsSync, lstatSync, statSync, createReadStream } = require("fs");
|
|
3
|
-
const { createServer } = require('http');
|
|
4
|
-
const packageValue = require("../package.json");
|
|
5
|
-
const network = require("./tools/network.js");
|
|
6
|
-
const mineTypes = require("./data/mineTypes.json");
|
|
7
|
-
const resolveImportFactory = require("./tools/resolveImport.js");
|
|
8
|
-
const openBrowser = require("./tools/openBrowser.js");
|
|
9
|
-
const { doIntercept } = require("./intercept.js");
|
|
10
|
-
const proxy = require("./proxy.js");
|
|
11
|
-
const resolve404_default = require("./tools/resolve404.js");
|
|
12
|
-
const websiteIntercept = require("./website-plugins/intercept/index.js");
|
|
13
|
-
const websiteLoader = require("./website-plugins/loader/index.js");
|
|
14
|
-
|
|
15
|
-
const WebSocketClass = require("./WebSocket/index.js");
|
|
16
|
-
|
|
17
|
-
// 开发服务器
|
|
18
|
-
module.exports = function (config) {
|
|
19
|
-
let startTime = new Date().valueOf();
|
|
20
|
-
|
|
21
|
-
const resolve404 = config.devServer["404"] || resolve404_default;
|
|
22
|
-
const cache = "cache" in config.devServer ? config.devServer.cache : true;
|
|
23
|
-
const website = "website" in config.devServer ? config.devServer.website : true;
|
|
24
|
-
const port = +config.devServer.port; // 端口号
|
|
25
|
-
const basePath = (/^\./.test(config.devServer.baseUrl)) ? join(process.cwd(), config.devServer.baseUrl) : config.devServer.baseUrl; // 服务器根路径
|
|
26
|
-
|
|
27
|
-
const name = (config.name || "OIPage") + "-http-server";
|
|
28
|
-
const version = config.version || packageValue.version;
|
|
29
|
-
|
|
30
|
-
const wsHandler = WebSocketClass(port + 1, (config.name || "OIPage") + "-ws-server", version, website);
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
let
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
let
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
'
|
|
84
|
-
'
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
'
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
1
|
+
const { join } = require("path");
|
|
2
|
+
const { existsSync, lstatSync, statSync, createReadStream } = require("fs");
|
|
3
|
+
const { createServer } = require('http');
|
|
4
|
+
const packageValue = require("../package.json");
|
|
5
|
+
const network = require("./tools/network.js");
|
|
6
|
+
const mineTypes = require("./data/mineTypes.json");
|
|
7
|
+
const resolveImportFactory = require("./tools/resolveImport.js");
|
|
8
|
+
const openBrowser = require("./tools/openBrowser.js");
|
|
9
|
+
const { doIntercept } = require("./intercept.js");
|
|
10
|
+
const proxy = require("./proxy.js");
|
|
11
|
+
const resolve404_default = require("./tools/resolve404.js");
|
|
12
|
+
const websiteIntercept = require("./website-plugins/intercept/index.js");
|
|
13
|
+
const websiteLoader = require("./website-plugins/loader/index.js");
|
|
14
|
+
|
|
15
|
+
const WebSocketClass = require("./WebSocket/index.js");
|
|
16
|
+
|
|
17
|
+
// 开发服务器
|
|
18
|
+
module.exports = function (config) {
|
|
19
|
+
let startTime = new Date().valueOf();
|
|
20
|
+
|
|
21
|
+
const resolve404 = config.devServer["404"] || resolve404_default;
|
|
22
|
+
const cache = "cache" in config.devServer ? config.devServer.cache : true;
|
|
23
|
+
const website = "website" in config.devServer ? config.devServer.website : true;
|
|
24
|
+
const port = +config.devServer.port; // 端口号
|
|
25
|
+
const basePath = (/^\./.test(config.devServer.baseUrl)) ? join(process.cwd(), config.devServer.baseUrl) : config.devServer.baseUrl; // 服务器根路径
|
|
26
|
+
|
|
27
|
+
const name = (config.name || "OIPage") + "-http-server";
|
|
28
|
+
const version = config.version || packageValue.version;
|
|
29
|
+
|
|
30
|
+
const wsHandler = WebSocketClass(port + 1, (config.name || "OIPage") + "-ws-server", version, website);
|
|
31
|
+
|
|
32
|
+
// 全局错误捕获,防止服务器因任何未捕获的错误而停机
|
|
33
|
+
process.on('uncaughtException', function (err) {
|
|
34
|
+
console.log("<i> \x1b[1m\x1b[31m[" + name + "] uncaughtException: " + err.message + "\x1b[0m " + new Date().toLocaleString());
|
|
35
|
+
console.log(err.stack);
|
|
36
|
+
});
|
|
37
|
+
process.on('unhandledRejection', function (reason) {
|
|
38
|
+
console.log("<i> \x1b[1m\x1b[31m[" + name + "] unhandledRejection: " + (reason && reason.message || reason) + "\x1b[0m " + new Date().toLocaleString());
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
let Server = createServer(function (request, response) {
|
|
42
|
+
let headers = request.headers;
|
|
43
|
+
let url = decodeURIComponent(request.url);
|
|
44
|
+
|
|
45
|
+
let urlArray = url.split("?");
|
|
46
|
+
url = urlArray[0];
|
|
47
|
+
|
|
48
|
+
// 请求的文件路径
|
|
49
|
+
let filePath;
|
|
50
|
+
|
|
51
|
+
let isWebsite = website && /^\/@website\//.test(url);
|
|
52
|
+
if (isWebsite) {
|
|
53
|
+
filePath = join(__dirname, "./website-htmls/", url.replace(/^\/@website\//, ""));
|
|
54
|
+
} else {
|
|
55
|
+
filePath = join(basePath, url == "/" ? "index.html" : url.replace(/^\//, ""));
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
let proxyIntercept = proxy({
|
|
59
|
+
name,
|
|
60
|
+
version
|
|
61
|
+
}, config.devServer.proxy || {});
|
|
62
|
+
delete config.devServer.proxy;
|
|
63
|
+
for (let i = 0; i < proxyIntercept.length; i++) {
|
|
64
|
+
config.devServer.intercept.push(proxyIntercept[i]);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// 请求拦截
|
|
68
|
+
if (doIntercept(url.replace(/^\/@website/, "").replace(/^\/@modules\//, ""), isWebsite ? websiteIntercept : config.devServer.intercept, request, response, wsHandler)) {
|
|
69
|
+
console.log("<i> \x1b[1m\x1b[32m[" + name + "] intercept: " + url + '\x1b[0m ' + new Date().toLocaleString());
|
|
70
|
+
} else {
|
|
71
|
+
|
|
72
|
+
// 对应前置都没有找到的,默认去当前命令行找
|
|
73
|
+
// 2026年4月13日 于南京
|
|
74
|
+
if (/^\/@modules\//.test(url)) {
|
|
75
|
+
filePath = join(process.cwd(), url.replace(/^\/@modules\//, "node_modules/"))
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
// 禁止访问沙箱外文件,路径穿越拦截
|
|
79
|
+
// 2026年8月8日 于南宁
|
|
80
|
+
if (!filePath.startsWith(basePath)) {
|
|
81
|
+
response.writeHead(403, {
|
|
82
|
+
'Content-Type': "text/plain;charset=utf-8",
|
|
83
|
+
'Access-Control-Allow-Origin': '*',
|
|
84
|
+
'Server': 'Powered by ' + name + '@' + version
|
|
85
|
+
});
|
|
86
|
+
response.write("Path Traversal attack");
|
|
87
|
+
response.end();
|
|
88
|
+
console.log("<i> \x1b[1m\x1b[31m[" + name + "] Path Traversal attack, path: " + url + "\x1b[0m " + new Date().toLocaleString());
|
|
89
|
+
return;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
// 如果存在且是文件
|
|
93
|
+
if (existsSync(filePath) && !lstatSync(filePath).isDirectory()) {
|
|
94
|
+
|
|
95
|
+
// 判断是否是请求而无需进一步解析
|
|
96
|
+
// 2025年12月5日 于南京
|
|
97
|
+
let isXHR = headers["sec-fetch-dest"] === "empty";
|
|
98
|
+
|
|
99
|
+
let dotName = /\./.test(filePath) ? filePath.match(/\.([^.]+)$/)[1] : "";
|
|
100
|
+
let fileType = mineTypes[dotName]; // 文件类型
|
|
101
|
+
let fileInfo = statSync(filePath);
|
|
102
|
+
|
|
103
|
+
let fileModifiedTime = new Date(fileInfo.mtime).toGMTString();
|
|
104
|
+
|
|
105
|
+
let responseHeader = {
|
|
106
|
+
'Content-Type': (fileType || "text/plain") + ";charset=utf-8",
|
|
107
|
+
'Access-Control-Allow-Origin': '*',
|
|
108
|
+
'Server': 'Powered by ' + name + '@' + version,
|
|
109
|
+
'Cache-Control': 'no-cache',
|
|
110
|
+
// 'Content-Length': fileInfo.size, // 会导致拦截修改的文本内容不对
|
|
111
|
+
|
|
112
|
+
// 与if-modified-since配合使用,做缓存验证
|
|
113
|
+
'Last-Modified': fileModifiedTime,
|
|
114
|
+
|
|
115
|
+
// 与if-none-match配合使用,做缓存验证
|
|
116
|
+
// 'ETag': basePath + "-" + new Date(fileInfo.mtime).toString()
|
|
117
|
+
};
|
|
118
|
+
|
|
119
|
+
if (cache && headers["if-modified-since"]) {
|
|
120
|
+
let ifModifiedSince = new Date(headers["if-modified-since"]).valueOf()
|
|
121
|
+
let lastModified = new Date(fileModifiedTime).valueOf()
|
|
122
|
+
|
|
123
|
+
// 注意这里不能使用<=,否则
|
|
124
|
+
// 1、会出现时区问题
|
|
125
|
+
// 2、作为开发服务器,可能同一个url地址对应的文件不同,被误判为未修改
|
|
126
|
+
// 2025年12月29日 于南京
|
|
127
|
+
// if (lastModified <= ifModifiedSince) {}
|
|
128
|
+
if (lastModified === ifModifiedSince) {
|
|
129
|
+
response.writeHead('304', responseHeader);
|
|
130
|
+
response.end();
|
|
131
|
+
console.log("<i> \x1b[1m\x1b[32m[" + name + "] Cache File: " + url + "\x1b[0m " + new Date().toLocaleString() + "\x1b[33m\x1b[1m 304" + (isXHR ? " " + request.method : "") + "\x1b[0m");
|
|
132
|
+
return;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
let sendType = "";
|
|
137
|
+
let entry = headers.accept !== "*/*";
|
|
138
|
+
|
|
139
|
+
// 如果文件小于10M,认为不大,直接读取
|
|
140
|
+
if (fileInfo.size < 10 * 1024 * 1024) {
|
|
141
|
+
let { source, resolveImport } = resolveImportFactory(basePath, filePath, entry, isWebsite ? websiteIntercept : config.devServer.intercept, urlArray[1] === "download", isWebsite)
|
|
142
|
+
|
|
143
|
+
// 只处理非下载文件
|
|
144
|
+
// 过大的也不进行处理
|
|
145
|
+
// (对website无效)
|
|
146
|
+
if (urlArray[1] !== "download") {
|
|
147
|
+
let loaders = isWebsite ? websiteLoader : config.module;
|
|
148
|
+
|
|
149
|
+
for (let i = 0; i < loaders.rules.length; i++) {
|
|
150
|
+
if (loaders.rules[i].test.test(filePath)) {
|
|
151
|
+
source = loaders.rules[i].use.call({
|
|
152
|
+
root: basePath, // 服务器根路径
|
|
153
|
+
path: filePath.replace(basePath, ""), // 文件相对路径
|
|
154
|
+
entry, // 是否是浏览器地址栏直接访问
|
|
155
|
+
setFileType(_fileType) { // 设置文件类型
|
|
156
|
+
fileType = _fileType;
|
|
157
|
+
responseHeader['Content-Type'] = _fileType + ";charset=utf-8";
|
|
158
|
+
}
|
|
159
|
+
}, source);
|
|
160
|
+
break;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
sendType = "Read";
|
|
167
|
+
response.writeHead('200', responseHeader);
|
|
168
|
+
response.write(isXHR ? source : resolveImport(source, fileType !== "application/javascript"));
|
|
169
|
+
response.end();
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
// 对于大文件,使用流读取
|
|
173
|
+
else {
|
|
174
|
+
sendType = "Stream";
|
|
175
|
+
|
|
176
|
+
responseHeader['Content-Length'] = fileInfo.size
|
|
177
|
+
|
|
178
|
+
response.writeHead('200', responseHeader);
|
|
179
|
+
createReadStream(filePath).pipe(response);
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
console.log("<i> \x1b[1m\x1b[32m[" + name + "] " + sendType + " File: " + url + '\x1b[0m ' + new Date().toLocaleString() + "\x1b[33m\x1b[1m" + (isXHR ? " " + request.method : "") + "\x1b[0m");
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
// 否则就是404
|
|
186
|
+
else {
|
|
187
|
+
response.writeHead(404, {
|
|
188
|
+
'Content-Type': "text/html;charset=utf-8",
|
|
189
|
+
'Access-Control-Allow-Origin': '*',
|
|
190
|
+
'Server': 'Powered by ' + name + '@' + version
|
|
191
|
+
});
|
|
192
|
+
response.write(resolve404(filePath, url, website, config.name || "OIPage"));
|
|
193
|
+
response.end();
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
});
|
|
198
|
+
|
|
199
|
+
Server.listen(port);
|
|
200
|
+
|
|
201
|
+
// 获取网络信息
|
|
202
|
+
let networkValue = network();
|
|
203
|
+
|
|
204
|
+
// 打印成功提示
|
|
205
|
+
console.log('<i> \x1b[1m\x1b[32m[' + name + '] Project is running at:\x1b[0m');
|
|
206
|
+
console.log('<i> \x1b[1m\x1b[32m[' + name + '] Loopback: \x1b[36mhttp://localhost:' + port + '/\x1b[0m');
|
|
207
|
+
for (let ipv4Item of networkValue.IPv4) console.log('<i> \x1b[1m\x1b[32m[' + name + '] On Your Network (IPv4):\x1b[36m http://' + ipv4Item.address + ':' + port + '/\x1b[0m');
|
|
208
|
+
for (let ipv6Item of networkValue.IPv6) console.log('<i> \x1b[1m\x1b[32m[' + name + '] On Your Network (IPv6): \x1b[36mhttp://[' + ipv6Item.address + ']:' + port + '/\x1b[0m');
|
|
209
|
+
console.log('<i> \x1b[1m\x1b[32m[' + name + '] Content not from ' + (config.name || "OIPage") + ' is served from \x1b[36m"' + basePath + '" \x1b[0mdirectory');
|
|
210
|
+
|
|
211
|
+
if (typeof config.devServer.open === "string" || config.devServer.open) {
|
|
212
|
+
let url = 'http://localhost:' + port + "/" + (typeof config.devServer.open === "string" ? config.devServer.open : "");
|
|
213
|
+
openBrowser(url);
|
|
214
|
+
console.log('<i> \x1b[1m\x1b[32m[' + name + '] Open: \x1b[36m' + url + '\x1b[0m');
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
if (!cache) console.log('<i> \x1b[1m\x1b[32m[' + name + '] Cancel 304 Cache!\x1b[0m');
|
|
218
|
+
console.log('\n' + (config.name || "OIPage") + ' ' + version + ' compiled \x1b[1m\x1b[32msuccessfully\x1b[0m in ' + (new Date().valueOf() - startTime) + ' ms\n');
|
|
196
219
|
};
|