declare-cc 0.5.3 → 0.5.4

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.
@@ -86,17 +86,15 @@ function killPort(port) {
86
86
  * Start the dashboard server for this project in the background.
87
87
  */
88
88
  function startServer() {
89
+ // Write port file before spawning so /declare:dashboard always finds it
90
+ try { fs.writeFileSync(portFile, String(port)); } catch {}
91
+
89
92
  const child = cp.spawn(process.execPath, [bundle, 'serve', '--port', String(port)], {
90
93
  cwd,
91
94
  detached: true,
92
95
  stdio: 'ignore',
93
96
  });
94
97
  child.unref();
95
-
96
- // Write port file so /declare:dashboard knows where to open
97
- setTimeout(() => {
98
- try { fs.writeFileSync(portFile, String(port)); } catch {}
99
- }, 800);
100
98
  }
101
99
 
102
100
  // Check if something is already running on this port
@@ -111,6 +109,8 @@ checkRunningServer(port, status => {
111
109
 
112
110
  // Nothing running (or non-Declare process) — kill whatever is there and start fresh
113
111
  killPort(port);
114
- setTimeout(startServer, 300);
115
- process.exit(0);
112
+ setTimeout(() => {
113
+ startServer();
114
+ process.exit(0);
115
+ }, 300);
116
116
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "declare-cc",
3
- "version": "0.5.3",
3
+ "version": "0.5.4",
4
4
  "description": "A future-driven meta-prompting engine for agentic development, rooted in declared futures and causal graph structure.",
5
5
  "bin": {
6
6
  "declare-cc": "bin/install.js"