terminal-pilot 0.0.32 → 0.0.33

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.
@@ -3731,7 +3731,6 @@ function defineCommand(config2) {
3731
3731
  import os2 from "node:os";
3732
3732
  import path9 from "node:path";
3733
3733
  import * as nodeFs from "node:fs/promises";
3734
- import { readFile as readFile2 } from "node:fs/promises";
3735
3734
 
3736
3735
  // src/errors.ts
3737
3736
  function hasOwnErrorCode3(error2, code) {
@@ -3781,19 +3780,15 @@ async function loadTerminalPilotTemplate() {
3781
3780
  if (terminalPilotTemplateCache !== void 0) {
3782
3781
  return terminalPilotTemplateCache;
3783
3782
  }
3784
- const candidates = [
3785
- new URL("./templates/terminal-pilot.md", import.meta.url),
3786
- new URL("../templates/terminal-pilot.md", import.meta.url),
3787
- new URL("../../../agent-skill-config/src/templates/terminal-pilot.md", import.meta.url)
3788
- ];
3789
- for (const candidate of candidates) {
3790
- try {
3791
- terminalPilotTemplateCache = await readFile2(candidate, "utf8");
3792
- return terminalPilotTemplateCache;
3793
- } catch (error2) {
3794
- if (!isNotFoundError(error2)) {
3795
- throw error2;
3796
- }
3783
+ try {
3784
+ terminalPilotTemplateCache = await nodeFs.readFile(
3785
+ new URL("../templates/terminal-pilot.md", import.meta.url),
3786
+ "utf8"
3787
+ );
3788
+ return terminalPilotTemplateCache;
3789
+ } catch (error2) {
3790
+ if (!isNotFoundError(error2)) {
3791
+ throw error2;
3797
3792
  }
3798
3793
  }
3799
3794
  throw new UserError("terminal-pilot skill template is missing.");