@volter/world 2.0.4 → 2.0.6

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/src/cli.js CHANGED
@@ -987,12 +987,16 @@ async function offerAgents() {
987
987
  }
988
988
  /** This package's version, for the MCP server's handshake. */
989
989
  function ownVersion() {
990
- try {
991
- return JSON.parse(readFileSync(fileURLToPath(new URL('../package.json', import.meta.url)), 'utf8')).version ?? '0.0.0';
992
- }
993
- catch {
994
- return '0.0.0';
990
+ // src/cli.ts in the repository, dist/src/cli.js in the published package: the package's manifest is one or two up
991
+ for (const up of ['../package.json', '../../package.json']) {
992
+ try {
993
+ const m = JSON.parse(readFileSync(fileURLToPath(new URL(up, import.meta.url)), 'utf8'));
994
+ if (m.name === '@volter/world' && m.version)
995
+ return m.version;
996
+ }
997
+ catch { /* not there */ }
995
998
  }
999
+ return '0.0.0';
996
1000
  }
997
1001
  async function main() {
998
1002
  const [noun, verb, ...args] = process.argv.slice(2);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@volter/world",
3
- "version": "2.0.4",
3
+ "version": "2.0.6",
4
4
  "description": "Run your app against a world of twins. `World` and `Repo` — one method per verb: init, up, run, log, diff, reset, branch, checkout, clone, fetch, changeset, push — and the `volter` command, one client of them.",
5
5
  "keywords": [
6
6
  "volter",
@@ -30,12 +30,12 @@
30
30
  ],
31
31
  "dependencies": {
32
32
  "@modelcontextprotocol/sdk": "^1.30.1",
33
- "@volter/world-core": "2.0.3",
34
- "@volter/world-runtime": "2.0.4",
33
+ "@volter/world-core": "2.0.4",
34
+ "@volter/world-runtime": "2.0.6",
35
35
  "zod": "^4.6.5"
36
36
  },
37
37
  "peerDependencies": {
38
- "@volter/world-console": "2.0.4"
38
+ "@volter/world-console": "2.0.6"
39
39
  },
40
40
  "peerDependenciesMeta": {
41
41
  "@volter/world-console": {
@@ -43,7 +43,7 @@
43
43
  }
44
44
  },
45
45
  "devDependencies": {
46
- "@volter/world-console": "2.0.4"
46
+ "@volter/world-console": "2.0.6"
47
47
  },
48
48
  "bin": {
49
49
  "volter": "dist/src/cli.js"
package/src/cli.ts CHANGED
@@ -723,7 +723,11 @@ async function offerAgents(): Promise<void> {
723
723
 
724
724
  /** This package's version, for the MCP server's handshake. */
725
725
  function ownVersion(): string {
726
- try { return (JSON.parse(readFileSync(fileURLToPath(new URL('../package.json', import.meta.url)), 'utf8')) as { version?: string }).version ?? '0.0.0'; } catch { return '0.0.0'; }
726
+ // src/cli.ts in the repository, dist/src/cli.js in the published package: the package's manifest is one or two up
727
+ for (const up of ['../package.json', '../../package.json']) {
728
+ try { const m = JSON.parse(readFileSync(fileURLToPath(new URL(up, import.meta.url)), 'utf8')) as { name?: string; version?: string }; if (m.name === '@volter/world' && m.version) return m.version; } catch { /* not there */ }
729
+ }
730
+ return '0.0.0';
727
731
  }
728
732
 
729
733
  async function main(): Promise<void> {