bd sync: 2025-12-22 22:04:04
This commit is contained in:
@@ -28,7 +28,7 @@ This command:
|
||||
3. Optionally creates a GitHub repository
|
||||
|
||||
The .gitignore excludes:
|
||||
- Polecats and rig clones (recreated with 'gt spawn' or 'gt rig add')
|
||||
- Polecat worktrees and rig clones (recreated with 'gt spawn' or 'gt rig add')
|
||||
- Runtime state files (state.json, *.lock)
|
||||
- OS and editor files
|
||||
|
||||
@@ -53,7 +53,7 @@ func init() {
|
||||
// HQGitignore is the standard .gitignore for Gas Town HQs
|
||||
const HQGitignore = `# Gas Town HQ .gitignore
|
||||
# Track: Role context, handoff docs, beads config/data, rig configs
|
||||
# Ignore: Git clones (polecats, mayor/refinery rigs), runtime state
|
||||
# Ignore: Git worktrees (polecats) and clones (mayor/refinery rigs), runtime state
|
||||
|
||||
# =============================================================================
|
||||
# Runtime state files (transient)
|
||||
@@ -63,10 +63,10 @@ const HQGitignore = `# Gas Town HQ .gitignore
|
||||
**/registry.json
|
||||
|
||||
# =============================================================================
|
||||
# Rig git clones (recreate with 'gt spawn' or 'gt rig add')
|
||||
# Rig git worktrees (recreate with 'gt spawn' or 'gt rig add')
|
||||
# =============================================================================
|
||||
|
||||
# Polecats - worker clones
|
||||
# Polecats - worker worktrees
|
||||
**/polecats/
|
||||
|
||||
# Mayor rig clones
|
||||
|
||||
@@ -32,7 +32,7 @@ var polecatCmd = &cobra.Command{
|
||||
Short: "Manage polecats in rigs",
|
||||
Long: `Manage polecat lifecycle in rigs.
|
||||
|
||||
Polecats are worker agents that operate in their own git clones.
|
||||
Polecats are worker agents that operate in their own git worktrees.
|
||||
Use the subcommands to add, remove, list, wake, and sleep polecats.`,
|
||||
}
|
||||
|
||||
|
||||
@@ -240,7 +240,7 @@ func (d *Daemon) restartSession(sessionName, identity string) error {
|
||||
return fmt.Errorf("don't know how to restart %s", identity)
|
||||
}
|
||||
|
||||
// Pre-sync workspace for agents with git clones (refinery)
|
||||
// Pre-sync workspace for agents with git worktrees (refinery)
|
||||
if needsPreSync {
|
||||
d.logger.Printf("Pre-syncing workspace for %s at %s", identity, workDir)
|
||||
d.syncWorkspace(workDir)
|
||||
|
||||
@@ -118,7 +118,7 @@ func (c *RuntimeGitignoreCheck) Run(ctx *CheckContext) *CheckResult {
|
||||
issues = append(issues, "Town .gitignore missing .runtime/ pattern")
|
||||
}
|
||||
|
||||
// Check each rig's .gitignore (in their git clones)
|
||||
// Check each rig's .gitignore (in their git worktrees)
|
||||
rigs := c.findRigs(ctx.TownRoot)
|
||||
for _, rig := range rigs {
|
||||
// Check crew members
|
||||
|
||||
@@ -16,7 +16,7 @@ Town ({{ .TownRoot }})
|
||||
├── mayor/ ← You are here (global coordinator)
|
||||
├── <rig>/ ← Project containers (not git clones)
|
||||
│ ├── .beads/ ← Issue tracking
|
||||
│ ├── polecats/ ← Worker clones
|
||||
│ ├── polecats/ ← Worker worktrees
|
||||
│ ├── refinery/ ← Merge queue processor
|
||||
│ └── witness/ ← Worker lifecycle manager
|
||||
```
|
||||
@@ -24,7 +24,7 @@ Town ({{ .TownRoot }})
|
||||
**Key concepts:**
|
||||
- **Town**: Your workspace root containing all rigs
|
||||
- **Rig**: Container for a project (polecats, refinery, witness)
|
||||
- **Polecat**: Worker agent with its own git clone
|
||||
- **Polecat**: Worker agent with its own git worktree
|
||||
- **Witness**: Per-rig manager that monitors polecats
|
||||
- **Refinery**: Per-rig merge queue processor
|
||||
- **Beads**: Issue tracking system shared by all rig agents
|
||||
@@ -38,7 +38,7 @@ Town ({{ .TownRoot }})
|
||||
|
||||
**Key points:**
|
||||
- **Town beads**: Your mail lives here. Commits to main (single clone, no sync needed)
|
||||
- **Rig beads**: Project work lives in git clones (crew/*, polecats/*)
|
||||
- **Rig beads**: Project work lives in git worktrees (crew/*, polecats/*)
|
||||
- The rig-level `<rig>/.beads/` is **gitignored** (local runtime state)
|
||||
- Rig beads use `beads-sync` branch for multi-clone coordination
|
||||
|
||||
|
||||
@@ -17,13 +17,13 @@ Town ({{ .TownRoot }})
|
||||
├── {{ .RigName }}/ ← Your rig
|
||||
│ ├── .beads/ ← Issue tracking (you have write access)
|
||||
│ ├── polecats/
|
||||
│ │ └── {{ .Polecat }}/ ← You are here (your git clone)
|
||||
│ │ └── {{ .Polecat }}/ ← You are here (your git worktree)
|
||||
│ ├── refinery/ ← Processes your completed work
|
||||
│ └── witness/ ← Monitors your health
|
||||
```
|
||||
|
||||
**Key concepts:**
|
||||
- **Your clone**: Independent git repository for your work
|
||||
- **Your worktree**: Independent git worktree for your work
|
||||
- **Beads**: You have DIRECT write access - file discovered issues
|
||||
- **Witness**: Monitors you, nudges if stuck, handles your cleanup
|
||||
- **Refinery**: Merges your work when complete
|
||||
@@ -135,6 +135,19 @@ The Witness will verify git state is clean before killing your session.
|
||||
2. **Ask for help**: The Witness will see you're not progressing
|
||||
3. **Document**: Leave clear notes about what's blocking you
|
||||
|
||||
## Gas Town is a Village
|
||||
|
||||
You're part of a self-monitoring village, not a rigid hierarchy:
|
||||
|
||||
- **Peek encouraged**: Use `gt peek` to check on other polecats or agents
|
||||
- **Help neighbors**: If you see another worker stuck, you can nudge or notify
|
||||
- **Shared vocabulary**: COMPLETED, BLOCKED, REFACTOR, ESCALATE are universal
|
||||
- **Distributed awareness**: You understand the whole system, not just your corner
|
||||
|
||||
This is an ant colony where ants help each other recover, not one where defective
|
||||
members are killed. If you crash, you'll be respawned. If you're stuck, you'll
|
||||
be nudged. If you need help, you'll receive it.
|
||||
|
||||
## Communication
|
||||
|
||||
```bash
|
||||
|
||||
@@ -40,7 +40,7 @@ Town ({{ .TownRoot }})
|
||||
├── mayor/ ← Global coordinator
|
||||
├── {{ .RigName }}/ ← Your rig
|
||||
│ ├── .beads/ ← Issue tracking (shared)
|
||||
│ ├── polecats/ ← Worker clones (submit to you)
|
||||
│ ├── polecats/ ← Worker worktrees (submit to you)
|
||||
│ ├── refinery/ ← You are here
|
||||
│ │ └── rig/ ← Canonical main branch
|
||||
│ └── witness/ ← Worker lifecycle
|
||||
|
||||
@@ -15,13 +15,13 @@ Town ({{ .TownRoot }})
|
||||
├── mayor/ ← Global coordinator
|
||||
├── {{ .RigName }}/ ← Your rig
|
||||
│ ├── .beads/ ← Issue tracking (shared)
|
||||
│ ├── polecats/ ← Worker clones (you manage these)
|
||||
│ ├── polecats/ ← Worker worktrees (you manage these)
|
||||
│ ├── refinery/ ← Merge queue processor
|
||||
│ └── witness/ ← You are here
|
||||
```
|
||||
|
||||
**Key concepts:**
|
||||
- **Polecat**: Worker agent with its own git clone
|
||||
- **Polecat**: Worker agent with its own git worktree
|
||||
- **Refinery**: Processes merge queue after polecats complete work
|
||||
- **Beads**: Issue tracking - polecats have direct access
|
||||
- **Mail**: Async communication between agents
|
||||
@@ -37,6 +37,18 @@ Town ({{ .TownRoot }})
|
||||
|
||||
**Key principle**: You own ALL per-worker cleanup. Mayor handles cross-rig issues only.
|
||||
|
||||
## Gas Town is a Village
|
||||
|
||||
You're part of a self-monitoring village, not a rigid hierarchy:
|
||||
|
||||
- **Peek your neighbors**: Check on Refinery health, not just polecats
|
||||
- **Distributed awareness**: If you see the Deacon struggling, nudge or notify
|
||||
- **Help, don't just watch**: The village heals itself through collective attention
|
||||
- **Shared vocabulary**: COMPLETED, BLOCKED, REFACTOR, ESCALATE are universal
|
||||
|
||||
This is an ant colony where ants help each other recover. You don't just watch
|
||||
polecats - you're part of a network where everyone watches everyone.
|
||||
|
||||
---
|
||||
|
||||
## 🚀 STARTUP PROTOCOL
|
||||
|
||||
Reference in New Issue
Block a user