tarsk 0.3.41 → 0.3.42

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.
Files changed (2) hide show
  1. package/dist/index.js +4 -2
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -6,6 +6,7 @@ import { cors } from "hono/cors";
6
6
  import { serve } from "@hono/node-server";
7
7
  import { serveStatic } from "@hono/node-server/serve-static";
8
8
  import path3 from "path";
9
+ import fs2 from "fs";
9
10
  import open3 from "open";
10
11
  import { fileURLToPath as fileURLToPath2 } from "url";
11
12
 
@@ -9830,8 +9831,9 @@ app.route("/api/git", createGitRoutes(metadataManager));
9830
9831
  app.route("/api/onboarding", createOnboardingRoutes(metadataManager));
9831
9832
  app.route("/api/scaffold", createScaffoldRoutes(projectManager));
9832
9833
  createSlashCommandRoutes(app, threadManager);
9833
- var isDev = true;
9834
- var publicDir = isDev ? path3.join(process.cwd(), "dist", "public") : path3.join(__dirname3, "public");
9834
+ var prodPublicDir = path3.join(__dirname3, "public");
9835
+ var devPublicDir = path3.join(process.cwd(), "dist", "public");
9836
+ var publicDir = fs2.existsSync(prodPublicDir) ? prodPublicDir : devPublicDir;
9835
9837
  var staticRoot = path3.relative(process.cwd(), publicDir);
9836
9838
  app.use("/*", async (c, next) => {
9837
9839
  if (c.req.path.startsWith("/api/")) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tarsk",
3
- "version": "0.3.41",
3
+ "version": "0.3.42",
4
4
  "description": "CLI for Tarsk - Project Threads Manager",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",