agent-stage 0.2.7 → 0.2.8
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.
|
@@ -16,9 +16,11 @@ function getTemplateDir() {
|
|
|
16
16
|
const currentFilePath = fileURLToPath(import.meta.url);
|
|
17
17
|
const currentDir = dirname(currentFilePath);
|
|
18
18
|
// Production: template is next to dist
|
|
19
|
-
|
|
19
|
+
// From dist/commands/dev/init.js -> dist/ -> package root
|
|
20
|
+
const prodPath = join(currentDir, '..', '..', '..', 'template');
|
|
20
21
|
// Development: template is in the source
|
|
21
|
-
|
|
22
|
+
// From packages/cli/src/commands/dev/init.ts -> packages/cli/
|
|
23
|
+
const devPath = join(currentDir, '..', '..', '..', '..', 'template');
|
|
22
24
|
if (existsSync(prodPath)) {
|
|
23
25
|
return prodPath;
|
|
24
26
|
}
|
|
@@ -195,8 +197,9 @@ async function configurePackageJson(targetDir) {
|
|
|
195
197
|
// Replace workspace:* with actual version or local path
|
|
196
198
|
// In dev mode (monorepo), use file: protocol to reference the local bridge package
|
|
197
199
|
// Check if we're in the monorepo by looking for packages/bridge from the CLI location
|
|
200
|
+
// From packages/cli/src/commands/dev/init.ts -> packages/cli/src/ -> packages/cli/ -> packages/
|
|
198
201
|
const currentFilePath = fileURLToPath(import.meta.url);
|
|
199
|
-
const localBridgePath = resolve(join(dirname(currentFilePath), '..', '..', '..', '..', '
|
|
202
|
+
const localBridgePath = resolve(join(dirname(currentFilePath), '..', '..', '..', '..', 'bridge'));
|
|
200
203
|
const isDev = existsSync(localBridgePath);
|
|
201
204
|
if (isDev) {
|
|
202
205
|
// In dev mode, use file: protocol to reference the local bridge package
|
|
@@ -211,8 +214,9 @@ async function configurePackageJson(targetDir) {
|
|
|
211
214
|
}
|
|
212
215
|
async function installDependencies(targetDir) {
|
|
213
216
|
// Check if we're in the monorepo by looking for packages/bridge from the CLI location
|
|
217
|
+
// From packages/cli/src/commands/dev/init.ts -> packages/cli/src/ -> packages/cli/ -> packages/
|
|
214
218
|
const currentFilePath = fileURLToPath(import.meta.url);
|
|
215
|
-
const localBridgePath = resolve(join(dirname(currentFilePath), '..', '..', '..', '..', '
|
|
219
|
+
const localBridgePath = resolve(join(dirname(currentFilePath), '..', '..', '..', '..', 'bridge'));
|
|
216
220
|
const isDev = existsSync(localBridgePath);
|
|
217
221
|
if (isDev) {
|
|
218
222
|
// In development mode (monorepo), use pnpm
|