提交 62ba7a5a 编写于 作者: V vben

chore: remove Chinese path warning

上级 a9c2a29d
......@@ -11,6 +11,8 @@
- 表单重置逻辑修改
- 关闭多标签页 tabs 动画
- 升级 vite 版本为`v1.0.0.rc6`
- 删除中文路径警告。rc6 已修复
- 更新部分组件文档
### 🐛 Bug Fixes
......
......@@ -4,7 +4,6 @@ import chalk from 'chalk';
import { argv } from 'yargs';
import { runChangeLog } from './changelog';
import { runPostInstall } from './postinstall';
import { runPreview } from './preview';
// import { runPreserve } from './preserve';
import { runBuild } from './build';
......@@ -27,10 +26,6 @@ switch (task) {
// runPreserve();
// break;
case 'postinstall':
runPostInstall();
break;
case 'preview':
runPreview();
break;
......
import { exec, which } from 'shelljs';
function ignoreCaseGit() {
try {
if (which('git').code === 0) {
exec('git config core.ignorecase false ');
}
} catch (error) {
console.log(error);
}
}
export function runPostInstall() {
ignoreCaseGit();
}
......@@ -4,25 +4,29 @@ import path from 'path';
import fs from 'fs-extra';
import { isEqual } from 'lodash';
import { sh } from 'tasksfile';
import { successConsole, errorConsole } from '../utils';
import {
successConsole,
// errorConsole
} from '../utils';
const resolve = (dir: string) => {
return path.resolve(process.cwd(), dir);
};
const reg = /[\u4E00-\u9FA5\uF900-\uFA2D]/;
// const reg = /[\u4E00-\u9FA5\uF900-\uFA2D]/;
let NEED_INSTALL = false;
export async function runPreserve() {
const cwdPath = process.cwd();
if (reg.test(cwdPath)) {
errorConsole(
'Do not include Chinese, Japanese or Korean in the full path of the project directory, please modify the directory name and run again!'
);
errorConsole('项目目录全路径请勿包含中文、日文、韩文,请修改目录名后再次重新运行!');
process.exit(1);
}
// rc.6 fixed
// const cwdPath = process.cwd();
// if (reg.test(cwdPath)) {
// errorConsole(
// 'Do not include Chinese, Japanese or Korean in the full path of the project directory, please modify the directory name and run again!'
// );
// errorConsole('项目目录全路径请勿包含中文、日文、韩文,请修改目录名后再次重新运行!');
// process.exit(1);
// }
fs.mkdirp(resolve('build/.cache'));
function checkPkgUpdate() {
......
......@@ -76,7 +76,7 @@
color: @white;
background: linear-gradient(
118deg,
rgba(@primary-color, 0.7),
rgba(@primary-color, 0.8),
rgba(@primary-color, 1)
) !important;
border: 0;
......
......@@ -620,14 +620,6 @@
dependencies:
"@types/node" "*"
"@types/glob@*":
version "7.1.3"
resolved "https://registry.npmjs.org/@types/glob/-/glob-7.1.3.tgz#e6ba80f36b7daad2c685acd9266382e68985c183"
integrity sha512-SEYeGAIQIQX8NN6LDKprLjbrd5dARM5EXsd8GI/A5l0apYI1fGMWgPHSe4ZKL4eozlAyI+doUE9XbYS4xCkQ1w==
dependencies:
"@types/minimatch" "*"
"@types/node" "*"
"@types/html-minifier@^4.0.0":
version "4.0.0"
resolved "https://registry.npmjs.org/@types/html-minifier/-/html-minifier-4.0.0.tgz#2065cb9944f2d1b241146707c6935aa7b947d279"
......@@ -737,11 +729,6 @@
resolved "https://registry.npmjs.org/@types/mime/-/mime-2.0.3.tgz#c893b73721db73699943bfc3653b1deb7faa4a3a"
integrity sha512-Jus9s4CDbqwocc5pOAnh8ShfrnMcPHuJYzVcSUU7lrh8Ni5HuIqX3oilL86p3dlTrk0LzHRCgA/GQ7uNCw6l2Q==
"@types/minimatch@*":
version "3.0.3"
resolved "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.3.tgz#3dca0e3f33b200fc7d1139c0cd96c1268cadfd9d"
integrity sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==
"@types/minimist@^1.2.0":
version "1.2.0"
resolved "https://registry.npmjs.org/@types/minimist/-/minimist-1.2.0.tgz#69a23a3ad29caf0097f06eda59b361ee2f0639f6"
......@@ -817,14 +804,6 @@
"@types/express-serve-static-core" "*"
"@types/mime" "*"
"@types/shelljs@^0.8.8":
version "0.8.8"
resolved "https://registry.npmjs.org/@types/shelljs/-/shelljs-0.8.8.tgz#e439c69929b88a2c8123c1a55e09eb708315addf"
integrity sha512-lD3LWdg6j8r0VRBFahJVaxoW0SIcswxKaFUrmKl33RJVeeoNYQAz4uqCJ5Z6v4oIBOsC5GozX+I5SorIKiTcQA==
dependencies:
"@types/glob" "*"
"@types/node" "*"
"@types/through@*":
version "0.0.30"
resolved "https://registry.npmjs.org/@types/through/-/through-0.0.30.tgz#e0e42ce77e897bd6aead6f6ea62aeb135b8a3895"
......@@ -6049,7 +6028,7 @@ shebang-regex@^3.0.0:
resolved "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172"
integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==
shelljs@^0.8.3, shelljs@^0.8.4:
shelljs@^0.8.3:
version "0.8.4"
resolved "https://registry.npmjs.org/shelljs/-/shelljs-0.8.4.tgz#de7684feeb767f8716b326078a8a00875890e3c2"
integrity sha512-7gk3UZ9kOfPLIAbslLzyWeGiEqx9e3rxwZM0KE6EL8GlGwjym9Mrlx5/p33bWTu9YG6vcS4MBxYZDHYr5lr8BQ==
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册