oh-my-opencode-slim 2.0.0-beta.7 → 2.0.0-beta.8

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.
@@ -1,5 +1,6 @@
1
1
  import type { PluginInput } from '@opencode-ai/plugin';
2
2
  import type { MultiplexerConfig } from '../config/schema';
3
+ import type { BackgroundJobBoard } from '../utils/background-job-board';
3
4
  interface SessionEvent {
4
5
  type: string;
5
6
  properties?: {
@@ -23,6 +24,7 @@ export declare function resetMultiplexerSessionManagerState(): void;
23
24
  * with polling kept as a fallback for reliability.
24
25
  */
25
26
  export declare class MultiplexerSessionManager {
27
+ private readonly backgroundJobBoard?;
26
28
  private instanceId;
27
29
  private serverUrl;
28
30
  private directory;
@@ -33,7 +35,7 @@ export declare class MultiplexerSessionManager {
33
35
  private closingSessions;
34
36
  private pollInterval?;
35
37
  private enabled;
36
- constructor(ctx: PluginInput, config: MultiplexerConfig);
38
+ constructor(ctx: PluginInput, config: MultiplexerConfig, backgroundJobBoard?: BackgroundJobBoard | undefined);
37
39
  onSessionCreated(event: SessionEvent): Promise<void>;
38
40
  onSessionStatus(event: SessionEvent): Promise<void>;
39
41
  onSessionDeleted(event: SessionEvent): Promise<void>;
@@ -46,6 +48,7 @@ export declare class MultiplexerSessionManager {
46
48
  private isTrackedOrSpawning;
47
49
  private updatePolling;
48
50
  private getSessionId;
51
+ private isRunningBackgroundJob;
49
52
  cleanup(): Promise<void>;
50
53
  }
51
54
  /**
@@ -1,3 +1,3 @@
1
- import { type ToolDefinition } from '@opencode-ai/plugin/tool';
1
+ import { type ToolDefinition } from '@opencode-ai/plugin';
2
2
  export declare const ast_grep_search: ToolDefinition;
3
3
  export declare const ast_grep_replace: ToolDefinition;
package/dist/tui.js CHANGED
@@ -4,29 +4,15 @@ var __getProtoOf = Object.getPrototypeOf;
4
4
  var __defProp = Object.defineProperty;
5
5
  var __getOwnPropNames = Object.getOwnPropertyNames;
6
6
  var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- function __accessProp(key) {
8
- return this[key];
9
- }
10
- var __toESMCache_node;
11
- var __toESMCache_esm;
12
7
  var __toESM = (mod, isNodeMode, target) => {
13
- var canCache = mod != null && typeof mod === "object";
14
- if (canCache) {
15
- var cache = isNodeMode ? __toESMCache_node ??= new WeakMap : __toESMCache_esm ??= new WeakMap;
16
- var cached = cache.get(mod);
17
- if (cached)
18
- return cached;
19
- }
20
8
  target = mod != null ? __create(__getProtoOf(mod)) : {};
21
9
  const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
22
10
  for (let key of __getOwnPropNames(mod))
23
11
  if (!__hasOwnProp.call(to, key))
24
12
  __defProp(to, key, {
25
- get: __accessProp.bind(mod, key),
13
+ get: () => mod[key],
26
14
  enumerable: true
27
15
  });
28
- if (canCache)
29
- cache.set(mod, to);
30
16
  return to;
31
17
  };
32
18
  var __commonJS = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
@@ -10,6 +10,7 @@ export interface BackgroundJobRecord {
10
10
  timedOut: boolean;
11
11
  terminalUnreconciled: boolean;
12
12
  launchedAt: number;
13
+ lastLaunchedAt: number;
13
14
  updatedAt: number;
14
15
  completedAt?: number;
15
16
  resultSummary?: string;
@@ -41,7 +42,7 @@ export declare class BackgroundJobBoard {
41
42
  list(parentSessionID?: string): BackgroundJobRecord[];
42
43
  hasRunning(parentSessionID: string): boolean;
43
44
  hasTerminalUnreconciled(parentSessionID: string): boolean;
44
- formatForPrompt(parentSessionID: string): string | undefined;
45
+ formatForPrompt(parentSessionID: string, now?: number): string | undefined;
45
46
  clearParent(parentSessionID: string): void;
46
47
  drop(taskID: string): void;
47
48
  private nextAlias;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oh-my-opencode-slim",
3
- "version": "2.0.0-beta.7",
3
+ "version": "2.0.0-beta.8",
4
4
  "description": "Lightweight agent orchestration plugin for OpenCode - a slimmed-down fork of oh-my-opencode",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -43,12 +43,13 @@
43
43
  "src/skills",
44
44
  "oh-my-opencode-slim.schema.json",
45
45
  "README.md",
46
+ "README.zh-CN.md",
46
47
  "LICENSE"
47
48
  ],
48
49
  "scripts": {
49
50
  "clean:dist": "bun -e \"import { rmSync } from 'node:fs'; rmSync('dist', { recursive: true, force: true })\"",
50
- "build:plugin": "bun build src/index.ts src/tui.ts --outdir dist --target node --format esm --external @ast-grep/napi --external @opencode-ai/plugin --external @opencode-ai/sdk --external @opentui/core --external @opentui/solid --external jsdom --external zod",
51
- "build:cli": "bun build src/cli/index.ts --outdir dist/cli --target node --format esm --external @ast-grep/napi --external @opencode-ai/plugin --external @opencode-ai/sdk --external jsdom --external zod",
51
+ "build:plugin": "bun build src/index.ts src/tui.ts --outdir dist --target node --format esm --external @ast-grep/napi --external @opencode-ai/plugin --external @opencode-ai/plugin/* --external @opencode-ai/sdk --external @opencode-ai/sdk/* --external @opentui/core --external @opentui/solid --external jsdom --external zod",
52
+ "build:cli": "bun build src/cli/index.ts --outdir dist/cli --target node --format esm --external @ast-grep/napi --external @opencode-ai/plugin --external @opencode-ai/plugin/* --external @opencode-ai/sdk --external @opencode-ai/sdk/* --external jsdom --external zod",
52
53
  "copy:divoom-assets": "bun run scripts/copy-divoom-assets.ts",
53
54
  "build": "bun run clean:dist && bun run build:plugin && bun run build:cli && bun run copy:divoom-assets && tsc --emitDeclarationOnly && bun run generate-schema",
54
55
  "prepare": "bun run build",