@openagents-org/agent-launcher 0.2.53 → 0.2.54

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/package.json +1 -1
  2. package/src/installer.js +2 -10
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openagents-org/agent-launcher",
3
- "version": "0.2.53",
3
+ "version": "0.2.54",
4
4
  "description": "OpenAgents Launcher — install, configure, and run AI coding agents from your terminal",
5
5
  "main": "src/index.js",
6
6
  "bin": {
package/src/installer.js CHANGED
@@ -52,17 +52,9 @@ class Installer {
52
52
  const binaryPath = this._whichBinary(agentType);
53
53
  if (!binaryPath) return false;
54
54
 
55
- // Verify it's not a stale shim — check the actual package exists
56
- // npm shims point to node_modules/<pkg>/ — if the package dir is gone, the shim is stale
57
- const entry = this.registry.getEntry(agentType);
58
- const npmPkg = entry && entry.install ? entry.install.npm_package : null;
59
- const binary = entry && entry.install ? entry.install.binary : agentType;
60
- const portableDir = path.join(os.homedir(), '.openagents', 'nodejs');
61
- const globalModules = path.join(portableDir, 'node_modules');
62
-
63
- // If the binary is in our portable dir, verify the package exists
55
+ // Verify it's not a stale shim — if binary is in our portable dir,
56
+ // check the actual package exists (reuse variables from above)
64
57
  if (binaryPath.startsWith(portableDir)) {
65
- const pkgDir = path.join(globalModules, npmPkg || binary);
66
58
  if (!fs.existsSync(path.join(pkgDir, 'package.json'))) {
67
59
  // Stale shim — clean it up from all possible locations
68
60
  for (const dir of [portableDir, path.join(globalModules, '.bin')]) {