plugins 1.2.10-canary.2 → 1.2.10-canary.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.
Files changed (2) hide show
  1. package/dist/index.js +16 -0
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -802,6 +802,22 @@ async function installToPluginCache(plugins, scope, repoPath, source) {
802
802
  }
803
803
  await writeFile(installedPath, JSON.stringify(installedData, null, 2));
804
804
  barDebug(c.dim("Updated installed_plugins.json"));
805
+ const settingsPath = join3(home, ".claude", "settings.json");
806
+ let settings = {};
807
+ if (existsSync2(settingsPath)) {
808
+ try {
809
+ settings = JSON.parse(await readFile2(settingsPath, "utf-8"));
810
+ } catch {
811
+ }
812
+ }
813
+ const enabled = settings.enabledPlugins ?? {};
814
+ for (const plugin of plugins) {
815
+ const pluginKey = `${plugin.name}@${marketplaceName}`;
816
+ enabled[pluginKey] = true;
817
+ }
818
+ settings.enabledPlugins = enabled;
819
+ await writeFile(settingsPath, JSON.stringify(settings, null, 2));
820
+ barDebug(c.dim("Updated settings.json enabledPlugins"));
805
821
  cachePopulated = true;
806
822
  }
807
823
  async function installToCursorExtensions(plugins, scope, repoPath, source) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "plugins",
3
- "version": "1.2.10-canary.2",
3
+ "version": "1.2.10-canary.3",
4
4
  "description": "Install open-plugin format plugins into agent tools",
5
5
  "type": "module",
6
6
  "bin": {