feat(cli): add --no-status flag to skip GraphQL status enrichment during sync

This commit is contained in:
teernisse
2026-02-16 09:43:36 -05:00
parent fc0d9cb1d3
commit b9063aa17a
4 changed files with 1222 additions and 8 deletions

View File

@@ -750,6 +750,7 @@ pub struct GenerateDocsArgs {
#[command(after_help = "\x1b[1mExamples:\x1b[0m
lore sync # Full pipeline: ingest + docs + embed
lore sync --no-embed # Skip embedding step
lore sync --no-status # Skip work-item status enrichment
lore sync --full --force # Full re-sync, override stale lock
lore sync --dry-run # Preview what would change")]
pub struct SyncArgs {
@@ -783,6 +784,10 @@ pub struct SyncArgs {
#[arg(long = "no-file-changes")]
pub no_file_changes: bool,
/// Skip work-item status enrichment via GraphQL (overrides config)
#[arg(long = "no-status")]
pub no_status: bool,
/// Preview what would be synced without making changes
#[arg(long, overrides_with = "no_dry_run")]
pub dry_run: bool,

View File

@@ -2046,6 +2046,9 @@ async fn handle_sync_cmd(
if args.no_file_changes {
config.sync.fetch_mr_file_changes = false;
}
if args.no_status {
config.sync.fetch_work_item_status = false;
}
let options = SyncOptions {
full: args.full && !args.no_full,
force: args.force && !args.no_force,
@@ -2337,7 +2340,7 @@ fn handle_robot_docs(robot_mode: bool, brief: bool) -> Result<(), Box<dyn std::e
},
"sync": {
"description": "Full sync pipeline: ingest -> generate-docs -> embed",
"flags": ["--full", "--no-full", "--force", "--no-force", "--no-embed", "--no-docs", "--no-events", "--no-file-changes", "--dry-run", "--no-dry-run"],
"flags": ["--full", "--no-full", "--force", "--no-force", "--no-embed", "--no-docs", "--no-events", "--no-file-changes", "--no-status", "--dry-run", "--no-dry-run"],
"example": "lore --robot sync",
"response_schema": {
"ok": "bool",
@@ -2478,7 +2481,7 @@ fn handle_robot_docs(robot_mode: bool, brief: bool) -> Result<(), Box<dyn std::e
"description": "Chronological timeline of events matching a keyword query or entity reference",
"flags": ["<QUERY>", "-p/--project", "--since <duration>", "--depth <n>", "--no-mentions", "-n/--limit", "--fields <list>", "--max-seeds", "--max-entities", "--max-evidence"],
"query_syntax": {
"search": "Any text -> hybrid search seeding (FTS + vector)",
"search": "Any text -> hybrid search seeding (FTS5 + vector)",
"entity_direct": "issue:N, i:N, mr:N, m:N -> direct entity seeding (no search, no Ollama)"
},
"example": "lore --robot timeline issue:42",
@@ -2642,11 +2645,14 @@ fn handle_robot_docs(robot_mode: bool, brief: bool) -> Result<(), Box<dyn std::e
"mr": "mrs",
"merge-requests": "mrs",
"merge-request": "mrs",
"note": "notes",
"find": "search",
"query": "search",
"stat": "stats",
"st": "status"
"mergerequests": "mrs",
"mergerequest": "mrs",
"generate-docs": "generate-docs",
"generatedocs": "generate-docs",
"gendocs": "generate-docs",
"gen-docs": "generate-docs",
"robot-docs": "robot-docs",
"robotdocs": "robot-docs"
},
"pre_clap_aliases": {
"note": "Underscore/no-separator forms auto-corrected before parsing",
@@ -2658,7 +2664,7 @@ fn handle_robot_docs(robot_mode: bool, brief: bool) -> Result<(), Box<dyn std::e
"generatedocs": "generate-docs",
"gendocs": "generate-docs",
"gen-docs": "generate-docs",
"robot_docs": "robot-docs",
"robot-docs": "robot-docs",
"robotdocs": "robot-docs"
},
"prefix_matching": "Enabled via infer_subcommands. Unambiguous prefixes work: 'iss' -> issues, 'time' -> timeline, 'sea' -> search"