rm -rf web && rm -rf wechatMp && rm -rf native
This commit is contained in:
parent
c951c37b68
commit
36f2ae82c2
|
|
@ -53,7 +53,7 @@ function parseCliArgs() {
|
||||||
|
|
||||||
\u9009\u9879:
|
\u9009\u9879:
|
||||||
--env=<environment> \u73AF\u5883\u7C7B\u578B (dev|prod|staging)\uFF0C\u9ED8\u8BA4: dev
|
--env=<environment> \u73AF\u5883\u7C7B\u578B (dev|prod|staging)\uFF0C\u9ED8\u8BA4: dev
|
||||||
--extra=<model> \u989D\u5916\u7684\u6A21\u578B\u76EE\u5F55\uFF08\u53EF\u591A\u6B21\u4F7F\u7528\uFF09
|
--extra=<model> \u989D\u5916\u7684\u4F9D\u8D56\u76EE\u5F55\uFF08\u53EF\u591A\u6B21\u4F7F\u7528\uFF09
|
||||||
--registry=<url> npm \u955C\u50CF\u7AD9\u5730\u5740\uFF0C\u9ED8\u8BA4: https://registry.npmmirror.com
|
--registry=<url> npm \u955C\u50CF\u7AD9\u5730\u5740\uFF0C\u9ED8\u8BA4: https://registry.npmmirror.com
|
||||||
--port=<port> \u66B4\u9732\u7684\u7AEF\u53E3\u53F7\uFF0C\u9ED8\u8BA4: 3001
|
--port=<port> \u66B4\u9732\u7684\u7AEF\u53E3\u53F7\uFF0C\u9ED8\u8BA4: 3001
|
||||||
--node-version=<ver> Node.js \u7248\u672C\uFF0C\u9ED8\u8BA4: 20
|
--node-version=<ver> Node.js \u7248\u672C\uFF0C\u9ED8\u8BA4: 20
|
||||||
|
|
@ -158,7 +158,7 @@ RUN npm install
|
||||||
dockerfile += `
|
dockerfile += `
|
||||||
# \u6E05\u7406 ${project}
|
# \u6E05\u7406 ${project}
|
||||||
WORKDIR /app/${project}
|
WORKDIR /app/${project}
|
||||||
RUN rm -rf src \\
|
RUN rm -rf src && rm -rf web && rm -rf wechatMp && rm -rf native \\
|
||||||
&& find node_modules -type d -name "test" -o -name "__tests__" -exec rm -rf {} + \\
|
&& find node_modules -type d -name "test" -o -name "__tests__" -exec rm -rf {} + \\
|
||||||
&& find node_modules -type f \\( -name "*.ts" -o -name "*.d.ts" \\) -delete
|
&& find node_modules -type f \\( -name "*.ts" -o -name "*.d.ts" \\) -delete
|
||||||
`;
|
`;
|
||||||
|
|
@ -263,7 +263,7 @@ function main() {
|
||||||
console.log(` \u9879\u76EE\u76EE\u5F55: ${projectDir}`);
|
console.log(` \u9879\u76EE\u76EE\u5F55: ${projectDir}`);
|
||||||
console.log(` \u73AF\u5883: ${options.env}`);
|
console.log(` \u73AF\u5883: ${options.env}`);
|
||||||
console.log(
|
console.log(
|
||||||
` \u989D\u5916\u6A21\u578B: ${options.extra.length > 0 ? options.extra.join(", ") : "\u65E0"}`
|
` \u989D\u5916\u4F9D\u8D56: ${options.extra.length > 0 ? options.extra.join(", ") : "\u65E0"}`
|
||||||
);
|
);
|
||||||
console.log(` npm \u955C\u50CF\u7AD9: ${options.registry}`);
|
console.log(` npm \u955C\u50CF\u7AD9: ${options.registry}`);
|
||||||
console.log(` \u7AEF\u53E3: ${options.port}`);
|
console.log(` \u7AEF\u53E3: ${options.port}`);
|
||||||
|
|
|
||||||
|
|
@ -201,7 +201,7 @@ RUN npm install
|
||||||
dockerfile += `
|
dockerfile += `
|
||||||
# 清理 ${project}
|
# 清理 ${project}
|
||||||
WORKDIR /app/${project}
|
WORKDIR /app/${project}
|
||||||
RUN rm -rf src \\
|
RUN rm -rf src && rm -rf web && rm -rf wechatMp && rm -rf native \\
|
||||||
&& find node_modules -type d -name "test" -o -name "__tests__" -exec rm -rf {} + \\
|
&& find node_modules -type d -name "test" -o -name "__tests__" -exec rm -rf {} + \\
|
||||||
&& find node_modules -type f \\( -name "*.ts" -o -name "*.d.ts" \\) -delete
|
&& find node_modules -type f \\( -name "*.ts" -o -name "*.d.ts" \\) -delete
|
||||||
`;
|
`;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue