@agentshouse/kit 0.2.1-alpha.13 → 0.2.1-alpha.15

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
@@ -17,6 +17,8 @@ Add `--container` to run House Kit in one Docker container instead, with your
17
17
  workspace mounted at `/agents/house`; your Agents then reach only that
18
18
  workspace. On Windows 11 the container is the one choice. Append a `kit` or
19
19
  `house` command to the container's command to run it in that container.
20
+ Running the command for the other choice on a connected computer asks you to
21
+ confirm, then replaces its Environment, whose Agents end, with a new one.
20
22
 
21
23
  On your own Ubuntu 26.04 server, run the Linux command with `--linux` to
22
24
  install House Kit natively, with its workspace at `/agents/house`; `kit` and
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
- "version": "0.2.1-alpha.13",
3
+ "version": "0.2.1-alpha.15",
4
4
  "hosts": {
5
5
  "linux": {
6
- "command": "bash <(curl -fsSL https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.13/connect-linux.sh)",
6
+ "command": "bash <(curl -fsSL https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.15/connect-linux.sh)",
7
7
  "asset": {
8
8
  "name": "connect-linux.sh",
9
- "url": "https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.13/connect-linux.sh"
9
+ "url": "https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.15/connect-linux.sh"
10
10
  },
11
11
  "workspace": {
12
12
  "argument": "--workspace",
@@ -17,10 +17,10 @@
17
17
  }
18
18
  },
19
19
  "windows": {
20
- "command": "& ([scriptblock]::Create((irm https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.13/connect-windows.ps1)))",
20
+ "command": "& ([scriptblock]::Create((irm https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.15/connect-windows.ps1)))",
21
21
  "asset": {
22
22
  "name": "connect-windows.ps1",
23
- "url": "https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.13/connect-windows.ps1"
23
+ "url": "https://github.com/agentshouse/kit/releases/download/v0.2.1-alpha.15/connect-windows.ps1"
24
24
  },
25
25
  "workspace": {
26
26
  "argument": "--workspace",
package/dist/git.js CHANGED
@@ -2,9 +2,9 @@ import { spawn } from 'node:child_process';
2
2
  import { createHash } from 'node:crypto';
3
3
  import { join } from 'node:path';
4
4
  import { withoutProxy } from './clis.js';
5
- import { agentBase } from './home.js';
5
+ import { workspaceRoot } from './home.js';
6
6
  export function workingCopies() {
7
- return join(agentBase(), 'working-copies');
7
+ return join(workspaceRoot(), 'working-copies');
8
8
  }
9
9
  export const HOUSE_REF = 'refs/house/received';
10
10
  const COMMITTER = 'House Kit <house-kit@localhost>';
package/dist/home.js CHANGED
@@ -6,9 +6,12 @@ const CONFIGURATION = 'kit.json';
6
6
  export function kitHome() {
7
7
  return process.env.HOUSE_KIT_HOME ?? join(homedir(), '.house-kit');
8
8
  }
9
- export function agentBase() {
9
+ export function workspaceRoot() {
10
10
  return process.env.HOUSE_KIT_WORKSPACE ?? '/agents/house';
11
11
  }
12
+ export function agentBase() {
13
+ return join(workspaceRoot(), 'agents');
14
+ }
12
15
  export async function readHome(name) {
13
16
  try {
14
17
  return JSON.parse(await readFile(join(kitHome(), name), 'utf8'));
package/dist/login.js CHANGED
@@ -71,11 +71,12 @@ export async function login(argv) {
71
71
  });
72
72
  const enrolled = await readEnrolment();
73
73
  const house = values.house ?? enrolled?.house ?? DEFAULT_HOUSE;
74
- const environment = values.environment ?? (enrolled?.house === house ? enrolled.environment : undefined);
74
+ const replaces = process.env.HOUSE_KIT_REPLACES;
75
+ const environment = replaces === undefined ? (values.environment ?? (enrolled?.house === house ? enrolled.environment : undefined)) : undefined;
75
76
  const verifier = randomBytes(32).toString('base64url');
76
77
  const started = {
77
78
  ...(environment === undefined
78
- ? { act: 'new_environment', label: hostname() }
79
+ ? { act: 'new_environment', label: hostname(), ...(replaces === undefined ? {} : { replaces }) }
79
80
  : { act: 'existing_environment', environment_id: environment }),
80
81
  code_challenge: createHash('sha256').update(verifier).digest('base64url'),
81
82
  };
package/dist/resident.js CHANGED
@@ -9,7 +9,7 @@ import { house } from './api.js';
9
9
  import { received } from './bridge.js';
10
10
  import { Conversations } from './conversations.js';
11
11
  import { WorkingCopies } from './copies.js';
12
- import { kitHome, readEnrolment } from './home.js';
12
+ import { agentBase, kitHome, readEnrolment } from './home.js';
13
13
  import { SignIns } from './sign-in.js';
14
14
  import { placeSkillSet } from './skills.js';
15
15
  import { holdStream } from './stream.js';
@@ -58,6 +58,7 @@ export async function resident() {
58
58
  return;
59
59
  }
60
60
  await placeSkillSet();
61
+ await mkdir(agentBase(), { recursive: true });
61
62
  process.env.HOUSE_KIT_RESIDENT = String(process.pid);
62
63
  const agents = new Agents(house);
63
64
  const copies = new WorkingCopies(house);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentshouse/kit",
3
- "version": "0.2.1-alpha.13",
3
+ "version": "0.2.1-alpha.15",
4
4
  "description": "House Kit connects an Environment to agents.house.",
5
5
  "license": "MIT",
6
6
  "repository": {