@flue/client 0.0.13 → 0.0.14

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/index.d.mts CHANGED
@@ -76,10 +76,10 @@ declare function transformEvent(raw: any): FlueEvent | null;
76
76
  interface FlueOptions {
77
77
  /** OpenCode server URL (default: 'http://localhost:48765'). */
78
78
  opencodeUrl?: string;
79
- /** Working directory used for OpenCode API calls (the repo root as seen by OpenCode). */
79
+ /** Working directory (the repo root on the host). */
80
80
  workdir: string;
81
- /** Override working directory for shell() calls (e.g. the host path when OpenCode runs in a container). */
82
- shellWorkdir?: string;
81
+ /** Override working directory for OpenCode API calls (e.g. /workspace inside a Docker container). */
82
+ containerWorkdir?: string;
83
83
  /** Working branch for commits. */
84
84
  branch?: string;
85
85
  /** Workflow arguments. */
@@ -139,7 +139,7 @@ declare class Flue {
139
139
  /** Scoped secrets passed by the runner. */
140
140
  readonly secrets: Record<string, string>;
141
141
  private readonly workdir;
142
- private readonly shellWorkdir;
142
+ private readonly containerWorkdir;
143
143
  private readonly model?;
144
144
  private readonly client;
145
145
  constructor(options: FlueOptions);
package/dist/index.mjs CHANGED
@@ -446,7 +446,7 @@ var Flue = class {
446
446
  /** Scoped secrets passed by the runner. */
447
447
  secrets;
448
448
  workdir;
449
- shellWorkdir;
449
+ containerWorkdir;
450
450
  model;
451
451
  client;
452
452
  constructor(options) {
@@ -454,11 +454,11 @@ var Flue = class {
454
454
  this.args = options.args ?? {};
455
455
  this.secrets = options.secrets ?? {};
456
456
  this.workdir = options.workdir;
457
- this.shellWorkdir = options.shellWorkdir ?? options.workdir;
457
+ this.containerWorkdir = options.containerWorkdir ?? options.workdir;
458
458
  this.model = options.model;
459
459
  this.client = createOpencodeClient({
460
460
  baseUrl: options.opencodeUrl ?? "http://localhost:48765",
461
- directory: options.workdir
461
+ directory: this.containerWorkdir
462
462
  });
463
463
  }
464
464
  async skill(name, options) {
@@ -470,7 +470,7 @@ var Flue = class {
470
470
  } : void 0,
471
471
  model: options?.model ?? this.model
472
472
  };
473
- return runSkill(this.client, this.workdir, name, mergedOptions);
473
+ return runSkill(this.client, this.containerWorkdir, name, mergedOptions);
474
474
  }
475
475
  async prompt(promptText, options) {
476
476
  const mergedOptions = {
@@ -478,13 +478,13 @@ var Flue = class {
478
478
  model: options?.model ?? this.model,
479
479
  prompt: promptText
480
480
  };
481
- return runSkill(this.client, this.workdir, "__inline__", mergedOptions);
481
+ return runSkill(this.client, this.containerWorkdir, "__inline__", mergedOptions);
482
482
  }
483
483
  /** Execute a shell command with scoped environment variables. */
484
484
  async shell(command, options) {
485
485
  return runShell(command, {
486
486
  ...options,
487
- cwd: options?.cwd ?? this.shellWorkdir
487
+ cwd: options?.cwd ?? this.workdir
488
488
  });
489
489
  }
490
490
  /** Close the OpenCode client connection. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flue/client",
3
- "version": "0.0.13",
3
+ "version": "0.0.14",
4
4
  "type": "module",
5
5
  "license": "Apache-2.0",
6
6
  "exports": {