-
Notifications
You must be signed in to change notification settings - Fork 1
Pipeline Plan 22
Seth Ford edited this page Feb 13, 2026
·
2 revisions
The plan is complete. Here's the implementation plan summary:
Extend sw-fleet.sh with a discover subcommand and fleet_rediscover_loop() background loop (same pattern as the existing fleet_rebalance() loop). Uses gh api REST calls for org repo listing, consistent with existing GitHub API patterns. Only 3 files need changes.
| File | Action | Purpose |
|---|---|---|
scripts/sw-fleet.sh |
Modify | Add discover subcommand, fleet_discover(), fleet_rediscover_loop(), topology in fleet_status()
|
scripts/sw-fleet-test.sh |
Modify | 13 test cases for discover, filters, opt-out, re-discovery, topology |
.claude/CLAUDE.md |
Modify | Document new commands and config keys |
- Add CLI argument parsing for
discoverflags (--org,--language,--activity-days,--topic,--has-issues,--include-forks,--merge,--dry-run) - Implement
fleet_discover()— GitHub org API call with pagination viagh api /orgs/{org}/repos --paginate - Implement filters — language, activity window, topics, has-issues, archived/disabled/fork exclusion
- Implement opt-out —
shipwright-ignoretopic +.shipwright-ignorefile detection - Implement config generation — build fleet-config.json, support
--mergewith existing config - Implement
--dry-runmode - Implement
fleet_rediscover_loop()— periodic background re-discovery withauto_discoverconfig key - Implement
fleet_add_repo()— hot-add new repos to running fleet - Add topology display to
fleet_status()— repos, machines, workers, auto-discover status - Wire
discoverinto command router and help text - Update
load_fleet_config()to parseauto_discoversettings - Write 13 test cases in
sw-fleet-test.sh - Update
.claude/CLAUDE.mddocumentation - Run full test suite and fix failures
-
Config schema: New
auto_discoverblock in fleet-config.json withenabled,org,interval_seconds, andfilters(language, activity_days, has_issues, topics, include_forks) -
Opt-out: Repos with
shipwright-ignoretopic in GitHub are excluded. Repos with a.shipwright-ignorefile are also excluded (checked viagh api /repos/{owner}/{repo}/contents/.shipwright-ignore) -
Re-discovery loop: Background process (like rebalancer) runs every
interval_seconds, calls discover with--merge, signals fleet viafleet-rediscover.flagfor hot-addition - Topology in status: Repos grouped by machine (local/remote), workers allocated, active/queued jobs, last activity, auto-discover last scan time
-
All Bash 3.2 compatible, atomic writes,
NO_GITHUBenv var respected