opencode-orchestrator 0.1.42 → 0.1.43

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/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # OpenCode Orchestrator Plugin
1
+ #OpenCode Orchestrator Plugin
2
2
 
3
3
  > **Multi-Agent Plugin for [OpenCode](https://opencode.ai)**
4
4
 
@@ -2,22 +2,24 @@
2
2
 
3
3
  // scripts/postinstall.ts
4
4
  import { existsSync, readFileSync, writeFileSync, mkdirSync } from "fs";
5
- import { join } from "path";
5
+ import { join, dirname } from "path";
6
6
  import { homedir } from "os";
7
+ import { fileURLToPath } from "url";
7
8
  var CONFIG_DIR = join(homedir(), ".config", "opencode");
8
9
  var CONFIG_FILE = join(CONFIG_DIR, "opencode.json");
9
10
  var PLUGIN_NAME = "opencode-orchestrator";
10
11
  function getPluginPath() {
11
12
  try {
12
- let currentDir = new URL(".", import.meta.url).pathname;
13
- while (currentDir !== "/" && currentDir !== ".") {
13
+ let currentDir = dirname(fileURLToPath(import.meta.url));
14
+ while (true) {
14
15
  if (existsSync(join(currentDir, "package.json"))) {
15
- return currentDir.replace(/\/$/, "");
16
+ return currentDir;
16
17
  }
17
- const parent = join(currentDir, "..");
18
- if (parent === currentDir)
18
+ const parentDir = dirname(currentDir);
19
+ if (parentDir === currentDir) {
19
20
  break;
20
- currentDir = parent;
21
+ }
22
+ currentDir = parentDir;
21
23
  }
22
24
  return PLUGIN_NAME;
23
25
  } catch {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-orchestrator",
3
- "version": "0.1.42",
3
+ "version": "0.1.43",
4
4
  "description": "6-Agent collaborative architecture for OpenCode - Make any model reliable",
5
5
  "author": "agnusdei1207",
6
6
  "license": "MIT",