Skip to content

Commit 2faabb7

Browse files
authored
fix: improve v2.4 setup and indexing flow (#11)
## Summary - Reworked `gather-step init` so existing `gather-step.config.yaml` files are respected, selected repos stay selected, and setup uses one numbered checkbox-style repo picker. - Added `gather-step watch N`, clearer indexing progress/logging, final elapsed time plus index-size output, and a loader while AI Markdown files are generated. - Reduced noisy parser warnings for static JSON/YAML mapping files and ambiguous sibling Python packages. - Updated v2.4 version metadata, changelog, landing-page copy, setup docs, CLI docs, and the CLI reference layout. Release-note drafts are ignored. ## Context / Motivation The setup flow was too easy to mistrust: rerunning `init` could fail on an existing config or reintroduce repos the user had already removed, indexing repeated repo discovery output, `watch N` was parsed as ignored intent, and progress/log messages read like internal implementation notes. The docs CLI reference page also had a sidebar/content overlap on desktop. ## Key Decisions - Treat existing config YAML as authoritative. Interactive init uses it as the default repo selection and preserves selected repo metadata such as custom `name`, `depth`, provider settings, and indexing rules. - Keep the repo picker terminal-native instead of adding a TUI dependency, so setup remains portable and script-friendly. - Leave ambiguous sibling Python package imports unresolved instead of choosing the first match, because an omitted edge is safer than a wrong edge for planning context. - Use `--force` as the explicit path for regenerating a fresh discovered config. ## Files Changed | Area | Files | Change | | --- | --- | --- | | Init/watch/generate CLI | `crates/gather-step-cli/src/commands/init.rs`, `watch.rs`, `generate.rs`, `mod.rs`, `tests/cli_init.rs` | Existing-config reuse, repo picker, `watch N`, AI Markdown loader, review fixes, copy polish, and regression coverage. | | Indexing UX/logging | `crates/gather-step-cli/src/commands/index.rs` | Shorter progress bar, current path display, start/finish logs, polished finalization copy, elapsed time, and index size. | | Parser warnings | `crates/gather-step-parser/src/tree_sitter.rs` | Skip SWC for static mapping files and avoid warning/noisy first-match Python package resolution. | | Release metadata | `Cargo.toml`, crate manifests, `Cargo.lock`, `website/package.json` | Bumped v2.4 metadata. | | Docs/site | `website/src/**`, `.gitignore` | v2.4 changelog, landing copy, setup/CLI docs, CLI reference layout constraints, and ignored local release-note drafts. | ## Cross-Repo / Rollout Impact None. This is local CLI/docs behavior in `thedoublejay/gather-step`. Existing workspaces can keep their config. After upgrading, users should rebuild generated state before relying on v2.4 output: ```bash gather-step --workspace /path/to/workspace reindex gather-step --workspace /path/to/workspace generate claude-md gather-step --workspace /path/to/workspace generate agents-md ``` ## Verification - [x] `cargo fmt --all -- --check` - [x] `cargo clippy -p gather-step -p gather-step-parser --all-targets -- -D warnings` - [x] `cargo test -p gather-step --lib` - [x] `cargo test -p gather-step --test cli_init` - [x] `cargo test -p gather-step repo_config_merge_filters_allow_list_to_selected_repos --lib` - [x] `cargo test -p gather-step repo_config_name_match_keeps_discovered_path --lib` - [x] `cargo test -p gather-step-parser --lib` - [x] `cd website && bun run build` - [x] `git diff --check` - [x] Previewed `/reference/cli/` locally and captured a Playwright screenshot at `1280x900` to confirm content no longer overlaps the sidebar. ## Follow-ups - Consider a separate generated-rules improvement pass using the Braingent v3 cleanup plan: freshness metadata, context budgets, and explicit retrieval/capture workflow pointers.
2 parents 2c66188 + ef22e4d commit 2faabb7

25 files changed

Lines changed: 825 additions & 181 deletions

File tree

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@ dist/
2828
# Local-only planning docs (superpowers plans, drafts, scratch)
2929
docs/superpowers/
3030

31+
# Local release-note drafts
32+
release-notes/
33+
3134
# Local-only Python private corpus benchmark inputs/results
3235
benchmark/python/private-corpus.local.yaml
3336
benchmark/python/private-results/

Cargo.lock

Lines changed: 9 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ members = [
1313
]
1414

1515
[workspace.package]
16-
version = "2.3.0"
16+
version = "2.4.0"
1717
authors = ["JJ Adonis"]
1818
edition = "2024"
1919
rust-version = "1.94.1"
@@ -23,11 +23,11 @@ homepage = "https://github.com/thedoublejay/gather-step"
2323
description = "High-performance multi-repo codebase intelligence engine"
2424

2525
[workspace.dependencies]
26-
gather-step-analysis = { path = "crates/gather-step-analysis", version = "2.3.0" }
27-
gather-step-core = { path = "crates/gather-step-core", version = "2.3.0" }
28-
gather-step-mcp = { path = "crates/gather-step-mcp", version = "2.3.0" }
29-
gather-step-parser = { path = "crates/gather-step-parser", version = "2.3.0" }
30-
gather-step-storage = { path = "crates/gather-step-storage", version = "2.3.0" }
26+
gather-step-analysis = { path = "crates/gather-step-analysis", version = "2.4.0" }
27+
gather-step-core = { path = "crates/gather-step-core", version = "2.4.0" }
28+
gather-step-mcp = { path = "crates/gather-step-mcp", version = "2.4.0" }
29+
gather-step-parser = { path = "crates/gather-step-parser", version = "2.4.0" }
30+
gather-step-storage = { path = "crates/gather-step-storage", version = "2.4.0" }
3131

3232
tree-sitter = "=0.26.8"
3333
tree-sitter-typescript = "0.23.2"

crates/gather-step-bench/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ harness = false
3030

3131
[dependencies]
3232
gather-step-core.workspace = true
33-
gather-step = { path = "../gather-step-cli", version = "2.3.0" }
33+
gather-step = { path = "../gather-step-cli", version = "2.4.0" }
3434
gather-step-mcp.workspace = true
3535
gather-step-storage.workspace = true
3636
anyhow.workspace = true

crates/gather-step-cli/Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ clap.workspace = true
2323
comfy-table.workspace = true
2424
console.workspace = true
2525
crossbeam-channel.workspace = true
26-
gather-step-analysis = { path = "../gather-step-analysis", version = "2.3.0" }
26+
gather-step-analysis = { path = "../gather-step-analysis", version = "2.4.0" }
2727
gather-step-core.workspace = true
28-
gather-step-git = { path = "../gather-step-git", version = "2.3.0" }
29-
gather-step-mcp = { path = "../gather-step-mcp", version = "2.3.0" }
30-
gather-step-output = { path = "../gather-step-output", version = "2.3.0" }
28+
gather-step-git = { path = "../gather-step-git", version = "2.4.0" }
29+
gather-step-mcp = { path = "../gather-step-mcp", version = "2.4.0" }
30+
gather-step-output = { path = "../gather-step-output", version = "2.4.0" }
3131
gather-step-parser.workspace = true
3232
gather-step-storage.workspace = true
3333
indicatif.workspace = true

crates/gather-step-cli/src/commands/generate.rs

Lines changed: 36 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ use gather_step_output::{
1212
render_workspace_summary_claude,
1313
};
1414
use gather_step_storage::{GraphStoreDb, MetadataStore, MetadataStoreDb};
15+
use indicatif::{ProgressBar, ProgressStyle};
1516
use serde::Serialize;
1617

1718
use crate::app::AppContext;
@@ -185,6 +186,7 @@ pub fn run_summary_pair(app: &AppContext) -> Result<()> {
185186
let output = app.output();
186187
let paths = app.workspace_paths();
187188
let metadata_path = paths.storage_root.join("metadata.sqlite");
189+
let generation_bar = ai_generation_bar(app);
188190

189191
if paths.graph_path.exists() && metadata_path.exists() {
190192
run_claude_md_rules(
@@ -196,11 +198,16 @@ pub fn run_summary_pair(app: &AppContext) -> Result<()> {
196198
},
197199
)?;
198200
} else {
199-
output.line("warning: skipped .claude/rules/ generation because no workspace index exists");
201+
output
202+
.line("Warning: Skipped generating .claude/rules/ because no workspace index exists.");
200203
output.line(
201-
"hint: run `gather-step index`, then `gather-step generate claude-md --target rules`",
204+
"Hint: Run `gather-step index`, then `gather-step generate claude-md --target rules`.",
202205
);
203206
}
207+
if let Some(bar) = &generation_bar {
208+
bar.inc(1);
209+
bar.set_message("Generating CLAUDE.gather.md...");
210+
}
204211

205212
run_claude_md_summary(
206213
app,
@@ -210,7 +217,33 @@ pub fn run_summary_pair(app: &AppContext) -> Result<()> {
210217
target: ClaudeMdTarget::Summary,
211218
},
212219
)?;
213-
run_agents_md(app, GenerateAgentsMdArgs { output: None })
220+
if let Some(bar) = &generation_bar {
221+
bar.inc(1);
222+
bar.set_message("Generating AGENTS.gather.md...");
223+
}
224+
run_agents_md(app, GenerateAgentsMdArgs { output: None })?;
225+
if let Some(bar) = generation_bar {
226+
bar.inc(1);
227+
bar.finish_and_clear();
228+
}
229+
Ok(())
230+
}
231+
232+
fn ai_generation_bar(app: &AppContext) -> Option<ProgressBar> {
233+
app.progress_is_visible().then(|| {
234+
let bar = app.multi_progress.add(ProgressBar::new(3));
235+
bar.set_style(
236+
ProgressStyle::with_template(
237+
" {spinner:.cyan.bold} [{elapsed_precise}] [{bar:40.cyan/blue}] {pos}/{len} {msg}",
238+
)
239+
.expect("AI context progress template is valid")
240+
.progress_chars("█░░")
241+
.tick_chars("⠋⠙⠹⠸⠼⠴⠦⠧⠇⠏ "),
242+
);
243+
bar.set_message("Generating AI context files...");
244+
bar.enable_steady_tick(std::time::Duration::from_millis(80));
245+
bar
246+
})
214247
}
215248

216249
fn run_codeowners(app: &AppContext, args: GenerateCodeownersArgs) -> Result<()> {

0 commit comments

Comments
 (0)