agent-enderun 0.0.3 → 0.0.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.
- package/CHANGELOG.md +7 -0
- package/README.md +3 -7
- package/bin/cli.js +4 -44
- package/package.json +1 -1
- package/pnpm-workspace.yaml +0 -3
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## [0.0.4] - 2026-05-09
|
|
6
|
+
|
|
7
|
+
### Changed
|
|
8
|
+
- Standardized package manager to npm across all documentation and CLI behavior.
|
|
9
|
+
- Removed pnpm and workspace protocol references from default agent setup.
|
|
10
|
+
- Simplified package manager detection to prefer npm and respect explicit overrides.
|
|
11
|
+
|
|
5
12
|
## [0.0.3] - 2026-05-09
|
|
6
13
|
|
|
7
14
|
### Fixed
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Agent Enderun (v0.0.
|
|
1
|
+
# Agent Enderun (v0.0.4)
|
|
2
2
|
|
|
3
3
|
[English](#english) | [Türkçe](#türkçe)
|
|
4
4
|
|
|
@@ -85,7 +85,6 @@ Agent Enderun detects the package manager automatically, but you can also force
|
|
|
85
85
|
```bash
|
|
86
86
|
AGENT_ENDERUN_PACKAGE_MANAGER=npm npx agent-enderun init gemini
|
|
87
87
|
AGENT_ENDERUN_PACKAGE_MANAGER=yarn npx agent-enderun init gemini
|
|
88
|
-
AGENT_ENDERUN_PACKAGE_MANAGER=pnpm npx agent-enderun init gemini
|
|
89
88
|
```
|
|
90
89
|
|
|
91
90
|
> Legacy environment variables `AI_ENDERUN_PACKAGE_MANAGER` and `AGENT_ENDERUN_PM` are still accepted for compatibility.
|
|
@@ -94,13 +93,11 @@ AGENT_ENDERUN_PACKAGE_MANAGER=pnpm npx agent-enderun init gemini
|
|
|
94
93
|
|
|
95
94
|
```bash
|
|
96
95
|
npx agent-enderun init gemini
|
|
97
|
-
|
|
96
|
+
npm install && npm run enderun:build
|
|
98
97
|
agent-enderun check
|
|
99
98
|
```
|
|
100
99
|
|
|
101
|
-
>
|
|
102
|
-
|
|
103
|
-
If you already use `pnpm` or `yarn`, the CLI will prefer the correct lockfile and runtime environment.
|
|
100
|
+
> Agent Enderun is built and optimized for npm. If you prefer yarn, you can explicitly set `AGENT_ENDERUN_PACKAGE_MANAGER=yarn`.
|
|
104
101
|
|
|
105
102
|
## CLI Quick Reference
|
|
106
103
|
|
|
@@ -231,7 +228,6 @@ Agent Enderun, paket yöneticisini otomatik algılar; ancak aşağıdaki değiş
|
|
|
231
228
|
```bash
|
|
232
229
|
AGENT_ENDERUN_PACKAGE_MANAGER=npm npx agent-enderun init gemini
|
|
233
230
|
AGENT_ENDERUN_PACKAGE_MANAGER=yarn npx agent-enderun init gemini
|
|
234
|
-
AGENT_ENDERUN_PACKAGE_MANAGER=pnpm npx agent-enderun init gemini
|
|
235
231
|
```
|
|
236
232
|
|
|
237
233
|
### Önerilen kurulum akışı
|
package/bin/cli.js
CHANGED
|
@@ -159,11 +159,6 @@ function mergePackageJson(targetPath, sourcePath) {
|
|
|
159
159
|
if (!targetPkg.version) targetPkg.version = "0.1.0";
|
|
160
160
|
if (!targetPkg.type) targetPkg.type = "module";
|
|
161
161
|
|
|
162
|
-
// Add workspaces if it's a new project or doesn't have them
|
|
163
|
-
if (!targetPkg.workspaces && !fs.existsSync(path.join(process.cwd(), "pnpm-workspace.yaml"))) {
|
|
164
|
-
targetPkg.workspaces = ["packages/*"];
|
|
165
|
-
}
|
|
166
|
-
|
|
167
162
|
// Add metadata
|
|
168
163
|
targetPkg.enderun = {
|
|
169
164
|
version: sourcePkg.version,
|
|
@@ -289,46 +284,12 @@ function getPackageManager() {
|
|
|
289
284
|
|
|
290
285
|
const userAgent = process.env.npm_config_user_agent || "";
|
|
291
286
|
const npmExecPath = process.env.npm_execpath || "";
|
|
292
|
-
const hasPnpmLock = fs.existsSync(path.join(process.cwd(), "pnpm-lock.yaml"));
|
|
293
|
-
const hasPnpmWorkspace = fs.existsSync(path.join(process.cwd(), "pnpm-workspace.yaml"));
|
|
294
|
-
const hasYarnLock = fs.existsSync(path.join(process.cwd(), "yarn.lock")) || fs.existsSync(path.join(process.cwd(), "yarn.lock.json"));
|
|
295
287
|
|
|
296
|
-
if (userAgent.includes("pnpm") || npmExecPath.includes("pnpm")) return "pnpm";
|
|
297
288
|
if (userAgent.includes("yarn") || npmExecPath.includes("yarn")) return "yarn";
|
|
298
|
-
|
|
299
|
-
if (hasPnpmLock || hasPnpmWorkspace || usesWorkspaceProtocol()) return "pnpm";
|
|
300
|
-
if (hasYarnLock) return "yarn";
|
|
289
|
+
|
|
301
290
|
return "npm";
|
|
302
291
|
}
|
|
303
292
|
|
|
304
|
-
function usesWorkspaceProtocol() {
|
|
305
|
-
try {
|
|
306
|
-
const rootPkgPath = path.join(process.cwd(), "package.json");
|
|
307
|
-
if (!fs.existsSync(rootPkgPath)) return false;
|
|
308
|
-
const data = JSON.parse(fs.readFileSync(rootPkgPath, "utf8"));
|
|
309
|
-
if (data.workspaces || String(data.packageManager || "").includes("pnpm")) return true;
|
|
310
|
-
const checkDeps = (deps) => deps && Object.values(deps).some(v => typeof v === "string" && v.startsWith("workspace:"));
|
|
311
|
-
return checkDeps(data.dependencies) || checkDeps(data.devDependencies) || checkDeps(data.peerDependencies) || checkDeps(data.optionalDependencies);
|
|
312
|
-
} catch {
|
|
313
|
-
return false;
|
|
314
|
-
}
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
function ensurePackageManagerAvailable(manager) {
|
|
318
|
-
if (manager !== "pnpm") return manager;
|
|
319
|
-
try {
|
|
320
|
-
execSync("pnpm --version", { stdio: "ignore" });
|
|
321
|
-
return "pnpm";
|
|
322
|
-
} catch {
|
|
323
|
-
try {
|
|
324
|
-
execSync("corepack enable pnpm", { stdio: "ignore" });
|
|
325
|
-
return "pnpm";
|
|
326
|
-
} catch {
|
|
327
|
-
return "npx pnpm";
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
}
|
|
331
|
-
|
|
332
293
|
/**
|
|
333
294
|
* Scaffold the framework into the target project.
|
|
334
295
|
*/
|
|
@@ -489,10 +450,9 @@ async function initCommand(selectedAdapter) {
|
|
|
489
450
|
}
|
|
490
451
|
|
|
491
452
|
const pkgMgr = getPackageManager();
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
const
|
|
495
|
-
const buildCmd = `${resolvedPkgMgr} run enderun:build`;
|
|
453
|
+
console.log(`\nℹ️ Detected package manager: ${pkgMgr}`);
|
|
454
|
+
const installCmd = pkgMgr === "npm" ? "npm install" : `${pkgMgr} install`;
|
|
455
|
+
const buildCmd = pkgMgr === "npm" ? "npm run enderun:build" : `${pkgMgr} run enderun:build`;
|
|
496
456
|
|
|
497
457
|
console.log("\n✨ Framework scaffolded! (v" + FRAMEWORK_VERSION + ")");
|
|
498
458
|
|
package/package.json
CHANGED
package/pnpm-workspace.yaml
DELETED