feat: reindex:all and daemon:install commands#137
Conversation
- `reindex:all` incrementally re-indexes and vectorizes all git repos in a configurable base path (default ~/projects). Supports --kind, --skip-vectorize filters. - `daemon:install` generates and installs systemd timer units with the current user/paths. Three timers: enhance (15min), sync (30min), reindex (6h). Supports --status and --uninstall. No bash scripts, no hardcoded paths. Portable across any systemd host. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThis PR introduces two new Laravel Zero commands: Changes
Sequence DiagramssequenceDiagram
participant User
participant DaemonCommand as DaemonInstallCommand
participant Process as Process Facade
participant SystemD as systemd
participant FileSystem as /etc/systemd/system
User->>DaemonCommand: handle() with --install
DaemonCommand->>DaemonCommand: determine user, home, PHP binary
loop for each unit (enhance, sync, reindex)
DaemonCommand->>DaemonCommand: buildService() & buildTimer()
DaemonCommand->>FileSystem: write temp files
DaemonCommand->>Process: copy to /etc/systemd/system
DaemonCommand->>Process: systemctl daemon-reload
DaemonCommand->>Process: systemctl enable timer
DaemonCommand->>Process: systemctl start timer
end
DaemonCommand->>DaemonCommand: showStatus()
DaemonCommand->>User: display timer status
sequenceDiagram
participant User
participant ReindexCommand as ReindexAllCommand
participant FileSystem as File System
participant SymbolService as SymbolIndexService
participant CodeService as CodeIndexerService
User->>ReindexCommand: handle() with --path --skip-vectorize
ReindexCommand->>FileSystem: validate base path
ReindexCommand->>FileSystem: enumerate git repositories
loop for each git repository
ReindexCommand->>SymbolService: indexFolder() with symbol kinds
SymbolService-->>ReindexCommand: success + symbol_count
alt skip-vectorize not set
ReindexCommand->>CodeService: ensureCollection()
ReindexCommand->>CodeService: vectorizeFromIndex()
end
ReindexCommand->>User: report per-repo results
end
ReindexCommand->>User: display aggregate results
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Possibly related PRs
Poem
✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
📊 Coverage Report
Files Below Threshold
🏆 Synapse Sentinel Gate |
🏆 Sentinel Certified✅ Tests & Coverage: 0 tests passed Add this badge to your README: [](https://github.com/conduit-ui/knowledge/actions/workflows/gate.yml) |
Summary
reindex:all— Incrementally re-indexes and vectorizes all git repos in a configurable base path. Supports--kind,--skip-vectorize,--pathflags.daemon:install— Generates and installs systemd timer units using the current user/paths at install time. Three timers: enhance (15min), sync (30min), reindex (6h).--statusto check,--uninstallto remove.Test plan
know daemon:installon target serversystemctl list-timers | grep knowledgeshows 3 timersGenerated with Claude Code
Summary by CodeRabbit
New Features
Tests