@csdwd/ai-teams-server 0.3.2 → 0.3.3

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 +7 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -2943,7 +2943,7 @@ if (isCli) {
2943
2943
  getArgValue2 = getArgValue, resolveDataDir2 = resolveDataDir, resolvePidFile2 = resolvePidFile, resolveLogDir2 = resolveLogDir, applyCliArgsToEnv2 = applyCliArgsToEnv;
2944
2944
  const args = process.argv.slice(2);
2945
2945
  if (args.includes("--version") || args.includes("-v")) {
2946
- console.log("0.3.2");
2946
+ console.log("0.3.3");
2947
2947
  process.exit(0);
2948
2948
  }
2949
2949
  if (args.includes("--help") || args.includes("-h")) {
@@ -2981,6 +2981,12 @@ if (isCli) {
2981
2981
  if (status.running) {
2982
2982
  await stopDaemon(resolvePidFile());
2983
2983
  }
2984
+ } else if (!process.env.__AI_TEAMS_DAEMON_WATCHDOG && !process.env.__AI_TEAMS_DAEMON_WORKER) {
2985
+ const status = getDaemonStatus(resolvePidFile());
2986
+ if (status.running) {
2987
+ console.log(`Already running (PID ${status.pid}).`);
2988
+ process.exit(0);
2989
+ }
2984
2990
  }
2985
2991
  applyCliArgsToEnv();
2986
2992
  if (!process.env.AI_TEAMS_AUTH_TOKEN) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@csdwd/ai-teams-server",
3
- "version": "0.3.2",
3
+ "version": "0.3.3",
4
4
  "description": "AI Teams central server — Fastify HTTP + WebSocket server for task dispatch, employee management, and web UI",
5
5
  "type": "module",
6
6
  "bin": {