i18-fe-automator-beta 2.0.1 → 2.0.3

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.
@@ -2505,10 +2505,11 @@ if (sass) {
2505
2505
 
2506
2506
  function translateUtil(appid, key, projectName, isLintFix) {
2507
2507
  const { input } = commander.program.opts();
2508
- let src = [input];
2508
+ const normalizedInput = input.replace(/\\/g, "/");
2509
+ let src = [normalizedInput];
2509
2510
  const isSrcDirectory = fs.statSync(input).isDirectory();
2510
2511
  if (isSrcDirectory) {
2511
- const directory = input + "/**/*.{js,vue,jsx,ts,tsx}";
2512
+ const directory = normalizedInput + "/**/*.{js,vue,jsx,ts,tsx}";
2512
2513
  src = glob.glob.sync(directory, {
2513
2514
  ignore: directory + `/**/node_modules/**`,
2514
2515
  });
@@ -2483,10 +2483,11 @@ if (sass) {
2483
2483
 
2484
2484
  function translateUtil(appid, key, projectName, isLintFix) {
2485
2485
  const { input } = program.opts();
2486
- let src = [input];
2486
+ const normalizedInput = input.replace(/\\/g, "/");
2487
+ let src = [normalizedInput];
2487
2488
  const isSrcDirectory = fs.statSync(input).isDirectory();
2488
2489
  if (isSrcDirectory) {
2489
- const directory = input + "/**/*.{js,vue,jsx,ts,tsx}";
2490
+ const directory = normalizedInput + "/**/*.{js,vue,jsx,ts,tsx}";
2490
2491
  src = glob.sync(directory, {
2491
2492
  ignore: directory + `/**/node_modules/**`,
2492
2493
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "i18-fe-automator-beta",
3
- "version": "2.0.1",
3
+ "version": "2.0.3",
4
4
  "description": "i18-fe-automator-beta内测版本,只用于key: ''替换、检测中文规则等",
5
5
  "type": "module",
6
6
  "bin": {