@llmist/cli 8.1.0 → 8.1.2

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/cli.js CHANGED
@@ -79,7 +79,7 @@ import { Command, InvalidArgumentError as InvalidArgumentError2 } from "commande
79
79
  // package.json
80
80
  var package_default = {
81
81
  name: "@llmist/cli",
82
- version: "8.0.0",
82
+ version: "8.1.2",
83
83
  description: "CLI for llmist - run LLM agents from the command line",
84
84
  type: "module",
85
85
  main: "dist/cli.js",
@@ -964,14 +964,18 @@ async function installGitPackage(spec, cacheDir) {
964
964
  const message = error instanceof Error ? error.message : String(error);
965
965
  throw new Error(`Failed to install dependencies for '${spec.package}': ${message}`);
966
966
  }
967
- try {
968
- const packageJson = JSON.parse(fs5.readFileSync(path4.join(cacheDir, "package.json"), "utf-8"));
969
- if (packageJson.scripts?.build) {
967
+ const packageJson = JSON.parse(fs5.readFileSync(path4.join(cacheDir, "package.json"), "utf-8"));
968
+ if (packageJson.scripts?.build) {
969
+ try {
970
970
  execSync("bun run build", { cwd: cacheDir, stdio: "inherit" });
971
+ } catch (error) {
972
+ const entryPoint = packageJson.llmist?.gadgets || "./dist/index.js";
973
+ const entryPointPath = path4.join(cacheDir, entryPoint);
974
+ if (!fs5.existsSync(entryPointPath)) {
975
+ const message = error instanceof Error ? error.message : String(error);
976
+ throw new Error(`Failed to build package '${spec.package}': ${message}`);
977
+ }
971
978
  }
972
- } catch (error) {
973
- const message = error instanceof Error ? error.message : String(error);
974
- throw new Error(`Failed to build package '${spec.package}': ${message}`);
975
979
  }
976
980
  }
977
981
  }