Commit Graph

14 Commits

Author SHA1 Message Date
Steve Yegge
32a623f801 fix: Tighten overseer validation, document fallback behavior 2025-12-29 18:31:58 -08:00
Steve Yegge
a09027043d feat: Add overseer identity for human operator mail support
Adds first-class support for the human overseer in Gas Town mail:

- New OverseerConfig in internal/config/overseer.go with identity
  detection (git config, gh cli, environment)
- Overseer detected/saved on town install (mayor/overseer.json)
- Simplified detectSender(): GT_ROLE set = agent, else = overseer
- New overseer address alongside mayor/ and deacon/
- Added --cc flag to mail send for CC recipients
- Inbox now includes CC'd messages via label query
- gt status shows overseer identity and unread mail count
- New gt whoami command shows current mail identity

Generated with Claude Code

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 18:02:49 -08:00
Steve Yegge
e8d4fcda0b Fix MessagingConfig code review issues (gt-mrqiz, gt-ngoe6, gt-akc4m)
- Add Type field for schema consistency (gt-mrqiz)
- Fix error message inconsistency: all validation errors now wrap sentinel (gt-ngoe6)
- Add missing tests: wrong type, future version, malformed JSON (gt-akc4m)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 15:31:25 -08:00
Steve Yegge
6fb4851301 Add messaging config types and load/save functions (gt-i6jvc)
Add MessagingConfig with:
- Lists: static mailing lists with fan-out delivery
- Queues: shared work queues with claiming
- Announces: bulletin boards for broadcast messages

Includes:
- types.go: MessagingConfig, QueueConfig, AnnounceConfig types
- loader.go: Load/Save/Validate functions, MessagingConfigPath helper
- loader_test.go: Round-trip and validation tests

Created ~/gt/config/messaging.json with example configuration.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 14:07:30 -08:00
Steve Yegge
efb2afbcca Add gt up --restore for crew and polecat restoration
Features:
- Add CrewConfig to RigSettings (settings/config.json)
- Add --restore flag to gt up
- Crew startup from natural language preferences (e.g., 'max', 'joe and max', 'all')
- Polecat restoration from hook files (work attached)

Example rig settings:
  {"crew": {"startup": "max"}}

Usage:
  gt up --restore

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 23:18:46 -08:00
Steve Yegge
42d8944f71 feat: default crew name to 'max', support town-level override
- Add DefaultCrewName constant ('max') to config package
- Add default_crew_name field to MayorConfig for town-level override
- Update gt rig add to resolve crew name: --crew flag > town config > default
- Update help text to reflect new default

Priority: --crew flag > MayorConfig.DefaultCrewName > config.DefaultCrewName ('max')
2025-12-23 04:47:07 -08:00
Steve Yegge
ba2db2bc11 feat: implement account management for multi-account Claude Code (gt-3133)
Adds support for managing multiple Claude Code accounts in Gas Town:

- accounts.json config parsing in mayor/ directory
- gt account list/add/default commands
- GT_ACCOUNT env var support with priority resolution
- --account flag on gt spawn and gt crew at commands
- CLAUDE_CONFIG_DIR injection into tmux sessions

Priority order: GT_ACCOUNT env var > --account flag > default from config

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 04:05:14 -08:00
Steve Yegge
97e0535bfe Implement three-tier config architecture (gt-k1lr tasks 1-5)
**Architecture changes:**
- Renamed `.gastown/` → `.runtime/` for runtime state (gitignored)
- Added `settings/` directory for rig behavioral config (git-tracked)
- Added `mayor/config.json` for town-level config (MayorConfig type)
- Separated RigConfig (identity) from RigSettings (behavioral)

**File location changes:**
- Town runtime: `~/.gastown/*` → `~/.runtime/*`
- Rig runtime: `<rig>/.gastown/*` → `<rig>/.runtime/*`
- Rig config: `<rig>/.gastown/config.json` → `<rig>/settings/config.json`
- Namepool state: `namepool.json` → `namepool-state.json`

**New types:**
- MayorConfig: town-level behavioral config
- RigSettings: rig behavioral config (merge_queue, theme, namepool)
- RigConfig now identity-only (name, git_url, beads, created_at)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 01:22:43 -08:00
Steve Yegge
ed089cbd17 Add role-based theming with layered config and doctor check
Role themes:
- witness: rust (red/alert)
- refinery: plum (purple)
- crew/polecat: inherit rig theme

Resolution order:
1. Per-rig role override (rig/.gastown/config.json role_themes)
2. Global role default (mayor/town.json theme.role_defaults)
3. Built-in role defaults
4. Rig theme (config or hash-based)

Config schema:
- TownConfig.Theme.RoleDefaults: global role->theme map
- RigConfig.Theme.RoleThemes: per-rig role overrides

Doctor check:
- Detects sessions with outdated theme format (brackets)
- Fixable with 'gt theme apply --all'

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 00:39:50 -08:00
Steve Yegge
900a440ce8 feat(namepool): Add themed name pools for polecats
Polecats now get themed names from the Mad Max universe by default
(furiosa, nux, slit, etc.) instead of generic polecat-01, polecat-02.

Changes:
- Add NamepoolConfig to config/types.go for per-rig theme configuration
- Update namepool.go with three built-in themes:
  - mad-max (default): furiosa, nux, imperator, etc.
  - minerals: obsidian, quartz, ruby, etc.
  - wasteland: rust, chrome, fury, etc.
- Add gt namepool commands: themes, set, add, reset
- Update manager.go to load namepool config from rig settings

Configuration in .gastown/config.json:
```json
{
  "namepool": {
    "style": "minerals",
    "max_before_numbering": 50
  }
}
```

Issue: beads-rs0

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-19 21:59:03 -08:00
Steve Yegge
4d0492fdf6 feat(tmux): add per-rig color themes and dynamic status line (gt-vc1n)
Add tmux status bar theming for Gas Town sessions:

- Per-rig color themes auto-assigned via consistent hashing
- 10 curated dark themes (ocean, forest, rust, plum, etc.)
- Special gold/dark theme for Mayor
- Dynamic status line showing current issue and mail count
- Mayor status shows polecat/rig counts

New commands:
- gt theme --list: show available themes
- gt theme apply: apply to running sessions
- gt issue set/clear: agents update their current issue
- gt status-line: internal command for tmux refresh

Status bar format:
- Left: [rig/worker] role
- Right: <issue> | <mail> | HH:MM

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-19 14:17:39 -08:00
Steve Yegge
3f924234ad feat(config): add merge_queue section to rig config schema
Add MergeQueueConfig struct and RigConfig type with:
- All merge queue settings (enabled, target_branch, on_conflict, etc.)
- Default values via DefaultMergeQueueConfig()
- Validation for on_conflict strategy and poll_interval duration
- Load/Save/Validate functions following existing config patterns
- Comprehensive tests for round-trip, custom config, and validation

Implements gt-h5n.8.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-19 00:29:40 -08:00
Steve Yegge
691971a16a feat: crew attach auto-detection, worktree polecats, beads mail
- gt crew at: auto-detect crew from cwd, run gt prime after launch
- Polecats now use git worktrees from refinery (faster than clones)
- Updated architecture.md for two-tier beads mail model
- Town beads (gm-*) for Mayor mail/coordination
- Rig .beads/ symlinks to refinery/rig/.beads

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 19:51:36 -08:00
Steve Yegge
e16931b304 feat: add config package with types and JSON serialization
Types:
- TownConfig: main town configuration (config/town.json)
- RigsConfig: rigs registry with BeadsConfig per rig
- AgentState: agent state with role, session, extras

Features:
- Load/Save functions for all types
- Version compatibility checks
- Required field validation
- Creates parent directories on save

Closes gt-f9x.1

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 13:24:28 -08:00