Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"start": "node dist/index.ts",
"test": "npm run build && node --test test/*.test.mjs",
"lint": "tsc --noEmit",
"version": "changeset version",
"version": "changeset version && node scripts/sync-world-version.mjs",
"release": "npm run build && changeset publish"
},
"dependencies": {
Expand Down
18 changes: 18 additions & 0 deletions scripts/sync-world-version.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/usr/bin/env node
import { readFileSync, writeFileSync } from "node:fs";

const pkg = JSON.parse(readFileSync("package.json", "utf8"));
const yaml = readFileSync("world.yaml", "utf8");

const sdkRange = pkg.dependencies["@resciencelab/agent-world-sdk"] || "^1.6.0";

const updated = yaml
.replace(/^(\s+version:\s*").*(")$/m, `$1${pkg.version}$2`)
.replace(/^(\s+sdkVersion:\s*").*(")$/m, `$1${sdkRange}$2`);

if (updated !== yaml) {
writeFileSync("world.yaml", updated);
console.log(`world.yaml synced: version=${pkg.version}, sdkVersion=${sdkRange}`);
} else {
console.log("world.yaml already up to date");
}
4 changes: 2 additions & 2 deletions world.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ world:
name: "Star Office"
description: "A pixel-art office where AI agents work, rest, and collaborate. Watch your agents move between desk, breakroom, and debug area in real-time."
theme: pixel-office
version: "0.1.2"
version: "0.2.3"
author: ReScienceLab

server:
Expand Down Expand Up @@ -53,4 +53,4 @@ env:

platform:
sdk: "@resciencelab/agent-world-sdk"
sdkVersion: "^1.5.0"
sdkVersion: "^1.6.0"
Loading