allagents 0.8.2 → 0.8.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 +28 -12
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -22743,26 +22743,42 @@ async function resolvePluginSpec(spec, options2 = {}) {
22743
22743
  return null;
22744
22744
  }
22745
22745
  const marketplaceName = options2.marketplaceNameOverride ?? parsed.marketplaceName;
22746
- const marketplace = await getMarketplace(marketplaceName);
22747
- if (!marketplace) {
22748
- return null;
22746
+ let marketplacePath = options2.marketplacePathOverride ?? null;
22747
+ if (!marketplacePath) {
22748
+ const marketplace = await getMarketplace(marketplaceName);
22749
+ if (!marketplace) {
22750
+ return null;
22751
+ }
22752
+ marketplacePath = marketplace.path;
22749
22753
  }
22750
- const manifestResult = await parseMarketplaceManifest(marketplace.path);
22754
+ const manifestResult = await parseMarketplaceManifest(marketplacePath);
22751
22755
  if (manifestResult.success) {
22752
22756
  const pluginEntry = manifestResult.data.plugins.find((p) => p.name === parsed.plugin);
22753
22757
  if (pluginEntry) {
22754
- const resolvedSource = typeof pluginEntry.source === "string" ? resolve4(marketplace.path, pluginEntry.source) : pluginEntry.source.url;
22755
- if (typeof resolvedSource === "string" && existsSync5(resolvedSource)) {
22756
- return {
22757
- path: resolvedSource,
22758
- marketplace: marketplaceName,
22759
- plugin: parsed.plugin
22760
- };
22758
+ if (typeof pluginEntry.source === "string") {
22759
+ const resolvedPath = resolve4(marketplacePath, pluginEntry.source);
22760
+ if (existsSync5(resolvedPath)) {
22761
+ return {
22762
+ path: resolvedPath,
22763
+ marketplace: marketplaceName,
22764
+ plugin: parsed.plugin
22765
+ };
22766
+ }
22767
+ } else {
22768
+ const fetchFn = options2.fetchFn ?? fetchPlugin;
22769
+ const fetchResult = await fetchFn(pluginEntry.source.url);
22770
+ if (fetchResult.success && fetchResult.cachePath) {
22771
+ return {
22772
+ path: fetchResult.cachePath,
22773
+ marketplace: marketplaceName,
22774
+ plugin: parsed.plugin
22775
+ };
22776
+ }
22761
22777
  }
22762
22778
  }
22763
22779
  }
22764
22780
  const subpath = options2.subpath ?? parsed.subpath ?? "plugins";
22765
- const pluginPath = join6(marketplace.path, subpath, parsed.plugin);
22781
+ const pluginPath = join6(marketplacePath, subpath, parsed.plugin);
22766
22782
  if (!existsSync5(pluginPath)) {
22767
22783
  return null;
22768
22784
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "allagents",
3
- "version": "0.8.2",
3
+ "version": "0.8.3",
4
4
  "description": "CLI tool for managing multi-repo AI agent workspaces with plugin synchronization",
5
5
  "type": "module",
6
6
  "bin": {