kaizen-agent 0.1.1 → 0.2.0

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/README.md CHANGED
@@ -29,9 +29,13 @@ cd ~/kaizen && bun run cli/install.ts
29
29
 
30
30
  Flags, either way:
31
31
 
32
+ Run interactively with no flags and it asks where to install; piped or scripted
33
+ runs take the global install without asking.
34
+
32
35
  | Flag | Effect |
33
36
  |---|---|
34
- | *(none)* | Install for every project, into `~/.claude/` |
37
+ | *(none)* | Ask, defaulting to every project (`~/.claude/`) |
38
+ | `--global` | Every project, no question asked |
35
39
  | `--project` | Install into `.claude/` in the current directory only |
36
40
  | `--check` | Report what is linked and exit non-zero if anything is missing |
37
41
  | `--force` | Replace a real file sitting where a link belongs |
package/cli/install.ts CHANGED
@@ -60,8 +60,21 @@ function linkState(src: string, dest: string) {
60
60
  const args = new Set(Bun.argv.slice(2));
61
61
  const check = args.has("--check");
62
62
  const force = args.has("--force");
63
- const root = args.has("--project") ? process.cwd() : home;
64
- const base = join(root, ".claude");
63
+ const base = join(await chooseRoot(), ".claude");
64
+
65
+ async function chooseRoot() {
66
+ if (args.has("--project")) return process.cwd();
67
+ if (args.has("--global") || check) return home;
68
+
69
+ // Only ask when there is someone to answer. Piped, scripted, or CI runs take the
70
+ // global install silently rather than hanging on a prompt nobody sees.
71
+ if (!process.stdin.isTTY) return home;
72
+
73
+ console.log(`\n 1 every project ${join(home, ".claude")}`);
74
+ console.log(` 2 this one only ${join(process.cwd(), ".claude")}\n`);
75
+ const answer = prompt("Install where? [1]") ?? "";
76
+ return answer.trim() === "2" ? process.cwd() : home;
77
+ }
65
78
 
66
79
  let bad = 0;
67
80
  for (const [src, sub] of links) {
@@ -91,4 +104,5 @@ if (check) {
91
104
  process.exit(bad ? 1 : 0);
92
105
  }
93
106
  console.log(`\nInstalled into ${base}. Restart Claude Code: skills load live, slash commands only on session start.`);
107
+ console.log(`Then, in a repository you want to use it on: /kaizen-init`);
94
108
  if (bad) process.exit(1);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kaizen-agent",
3
- "version": "0.1.1",
3
+ "version": "0.2.0",
4
4
  "description": "Staged AI development workflow: plan, human approval, implement, independent review, bounded fix loop.",
5
5
  "type": "module",
6
6
  "bin": {