zixulu 1.75.0 → 1.75.2

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/dist/index.js CHANGED
@@ -1101,11 +1101,13 @@ export default defineConfig([
1101
1101
  globals: globals.browser,
1102
1102
  },
1103
1103
  rules: {
1104
+ "@typescript-eslint/no-explicit-any": "off",
1104
1105
  "@typescript-eslint/no-empty-object-type": "off",
1106
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "off",
1105
1107
  "no-empty": "off",
1106
1108
  "no-extra-boolean-cast": "off",
1107
1109
  "no-unused-vars": "off",${isReact ? `
1108
- "react-refresh/only-export-components": "warn",` : ""}
1110
+ "react-refresh/only-export-components": "off",` : ""}
1109
1111
  "@typescript-eslint/no-unused-vars": [
1110
1112
  "warn",
1111
1113
  {
@@ -4650,6 +4652,7 @@ var syncVscode_VscodeSyncOption = /*#__PURE__*/ function(VscodeSyncOption) {
4650
4652
  VscodeSyncOption["配置"] = "SETTING";
4651
4653
  VscodeSyncOption["插件"] = "EXTENSION";
4652
4654
  VscodeSyncOption["软件"] = "SOFTWARE";
4655
+ VscodeSyncOption["PowerShell"] = "POWERSHELL";
4653
4656
  return VscodeSyncOption;
4654
4657
  }({});
4655
4658
  async function syncVscode() {
@@ -4722,8 +4725,11 @@ ${options.includes("EXTENSION") ? ` const dir = await readdir("./extensions")
4722
4725
  for (const file of dir2) {
4723
4726
  await rm(join(snippetTarget, file), { force: true })
4724
4727
  await copyFile(join("./snippets", file), join(snippetTarget, file))
4725
- }
4726
- ` : ""}}
4728
+ }` : ""}${options.includes("POWERSHELL") ? `
4729
+ ${options.includes("SETTING") ? "" : `const userDir = homedir()
4730
+ `}const profile = join(userDir, "Documents/PowerShell/Microsoft.PowerShell_profile.ps1")
4731
+ await copyFile("./Microsoft.PowerShell_profile.ps1", profile)` : ""}
4732
+ }
4727
4733
 
4728
4734
  main()`;
4729
4735
  await writeFile(join(dir, "syncVscode.mjs"), script, "utf-8");
@@ -4733,6 +4739,14 @@ main()`;
4733
4739
  await download_download("https://code.visualstudio.com/sha/download?build=stable&os=win32-x64", dir);
4734
4740
  consola_0.success("下载最新 VSCode 完成");
4735
4741
  }
4742
+ if (options.includes("POWERSHELL")) {
4743
+ consola_0.start("开始同步 PowerShell 配置");
4744
+ const userDir = homedir();
4745
+ const profile = join(userDir, "Documents/PowerShell/Microsoft.PowerShell_profile.ps1");
4746
+ const content = await readFile(profile, "utf-8");
4747
+ await writeFile(join(dir, "Microsoft.PowerShell_profile.ps1"), content.replace(/cursor|antigravity/g, "code"));
4748
+ consola_0.success("同步 PowerShell 配置成功");
4749
+ }
4736
4750
  } catch (error) {
4737
4751
  const { clear } = await inquirer_0.prompt({
4738
4752
  type: "confirm",