Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/gemini-md-onboarding.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@taskless/cli": patch
---

Onboarding now reads Gemini CLI's `GEMINI.md` as an agent-memory source, including nested copies and any file `context.fileName` in `.gemini/settings.json` renames it to, and the report credits it under `agent-files`. Install detection of Gemini CLI from `GEMINI.md` or `.gemini/` is now covered by tests.
12 changes: 8 additions & 4 deletions packages/cli/src/agent/onboard.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Topic: onboard (CLI v%(CLI_VERSION)s / topic v15)
# Topic: onboard (CLI v%(CLI_VERSION)s / topic v16)

%(ONE_COMMAND_PER_CALL)s

Expand Down Expand Up @@ -168,8 +168,12 @@ Use all of these that apply:
and `HACK` comments. Many of these are latent rules ("don't do
this", "remove when X").
- **Agent-memory files**: read `CLAUDE.md`, `AGENTS.md`,
`.cursorrules`, `.opencode/AGENTS.md`, and similar agent-context
files for explicit rules and conventions stated in prose.
`GEMINI.md`, `.cursorrules`, `.opencode/AGENTS.md`, and similar
agent-context files for explicit rules and conventions stated in
prose. Gemini CLI also reads a `GEMINI.md` in any subdirectory, and
`context.fileName` in `.gemini/settings.json` can rename the file
(a string or a list of names), so read whatever that setting names
too.
%(SOURCE_PR_REVIEW)s
- **Commit history**: read the commit messages over the same window
for fixes that recur: the same missing header added again, the
Expand Down Expand Up @@ -232,7 +236,7 @@ pattern, under its kind:
- `commits`: a commit in the window that made the fix
- `issues`: an issue, ticket, recorded decision, or a comment on one
- `conventions`: a TODO, FIXME, XXX, or HACK comment asking for it
- `agent-files`: a line in CLAUDE.md, AGENTS.md, or similar
- `agent-files`: a line in CLAUDE.md, AGENTS.md, GEMINI.md, or similar
- `docs`: a passage in the docs, `@deprecated` and the like included
- `tests`: a test that pins the behaviour

Expand Down
4 changes: 2 additions & 2 deletions packages/cli/src/agent/report.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Topic: report (CLI v%(CLI_VERSION)s / topic v10)
# Topic: report (CLI v%(CLI_VERSION)s / topic v11)

%(ONE_COMMAND_PER_CALL)s

Expand Down Expand Up @@ -173,7 +173,7 @@ pattern. Code that merely follows a pattern is not a call-out.
| `reviews` | a review comment; its count is `surfaced`, not evidence |
| `commits` | a commit inside `window` that made the fix |
| `issues` | an issue, ticket, recorded decision, or comment on one |
| `agent-files` | a line in CLAUDE.md, AGENTS.md, or similar |
| `agent-files` | a line in CLAUDE.md, AGENTS.md, GEMINI.md, or similar |
| `conventions` | a TODO, FIXME, XXX, or HACK comment asking for it |
| `docs` | a docs passage, `@deprecated` and the like included |
| `tests` | a test that pins the behaviour |
Expand Down
14 changes: 14 additions & 0 deletions packages/cli/test/install.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,20 @@ describe("detectTools", () => {
expect(tools[0]!.name).toBe("Cursor");
});

it("detects Gemini CLI via .gemini/ directory", async () => {
await mkdir(join(cwd, ".gemini"), { recursive: true });
const tools = await detectTools(cwd);
expect(tools).toHaveLength(1);
expect(tools[0]!.name).toBe("Gemini CLI");
});

it("detects Gemini CLI via GEMINI.md file", async () => {
await writeFile(join(cwd, "GEMINI.md"), "", "utf8");
const tools = await detectTools(cwd);
expect(tools).toHaveLength(1);
expect(tools[0]!.name).toBe("Gemini CLI");
});

it("returns multiple tools when multiple signals exist", async () => {
await mkdir(join(cwd, ".claude"), { recursive: true });
await mkdir(join(cwd, ".cursor"), { recursive: true });
Expand Down
4 changes: 2 additions & 2 deletions packages/cli/test/onboard.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -422,8 +422,8 @@ describe("onboard recipe asks one question and finishes on its own", () => {
: stdout.slice(start, start + title.length + next);
}

it("is topic v15", () => {
expect(stdout).toMatch(/^# Topic: onboard {5}\(CLI v.+ \/ topic v15\)/m);
it("is topic v16", () => {
expect(stdout).toMatch(/^# Topic: onboard {5}\(CLI v.+ \/ topic v16\)/m);
});

// v10 (#554): a worktree holds only commits, and `init` commits nothing, so
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/test/report.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1416,7 +1416,7 @@ describe("taskless report", () => {
// The counting and estimating guidance is on demand (#672); --full prints it.
const { stdout, exitCode } = await run(["agent", "report", "--full"]);
expect(exitCode).toBe(0);
expect(stdout).toMatch(/^# Topic: report {5}\(CLI v.+ \/ topic v10\)/m);
expect(stdout).toMatch(/^# Topic: report {5}\(CLI v.+ \/ topic v11\)/m);
const flat = stdout.replaceAll(/\s+/g, " ");
const counting = flat.slice(flat.indexOf("## Counting evidence"));
expect(counting).toContain(
Expand Down