gemini-cli-devtools 0.1.0 → 0.1.1
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/src/index.js +7 -1
- package/package.json +1 -1
package/dist/src/index.js
CHANGED
|
@@ -11,7 +11,13 @@ import os from 'node:os';
|
|
|
11
11
|
import { fileURLToPath } from 'node:url';
|
|
12
12
|
import { WebSocketServer } from 'ws';
|
|
13
13
|
const VITE_DEV_PORT = 5174;
|
|
14
|
-
|
|
14
|
+
// Check if running in dev mode by looking for src directory (not in npm package)
|
|
15
|
+
const isDev = (() => {
|
|
16
|
+
const srcDir = path.dirname(fileURLToPath(import.meta.url));
|
|
17
|
+
// In dev: src/index.ts -> srcDir is "src"
|
|
18
|
+
// In prod: dist/src/index.js -> srcDir is "dist/src"
|
|
19
|
+
return srcDir.endsWith('/src') && !srcDir.includes('/dist/');
|
|
20
|
+
})();
|
|
15
21
|
/**
|
|
16
22
|
* DevTools Viewer
|
|
17
23
|
*
|