You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Consolidate project knowledge base (AGENTS.md) and Claude Code
guidance (CLAUDE.md) into a single file. Update CONTRIBUTING.md
reference accordingly.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
OpenBoot is a macOS-only CLI tool (Go 1.24) that automates dev environment setup — Homebrew packages/casks, npm globals, shell config (Oh-My-Zsh), macOS preferences, and dotfiles. Built with Cobra (CLI) and Charmbracelet (bubbletea/lipgloss/huh for TUI).
11
8
12
-
## STRUCTURE
9
+
## Commands
10
+
11
+
```bash
12
+
# Build
13
+
make build # Dev build (version=dev)
14
+
make build VERSION=0.24.0 # Specific version
15
+
make build-release VERSION=0.24.0 # Optimized + UPX compression
16
+
17
+
# Test
18
+
make test-unit # go test -v -timeout 5m ./...
19
+
make test-integration # go test -v -tags=integration ./...
20
+
make test-e2e # go test -v -tags=e2e -short ./...
21
+
make test-all # All tests + coverage report
22
+
23
+
# Run a single test
24
+
go test -v -run TestFunctionName ./internal/package/...
| Update self-update |`internal/updater/updater.go`| AutoUpgrade() called from root.go RunE |
55
-
| Modify presets |`internal/config/data/presets.yaml`| 3 presets: minimal, developer, full |
56
-
57
-
## DEPENDENCY GRAPH
69
+
### Dependency Graph
58
70
59
71
```
60
72
cli (root)
@@ -73,61 +85,58 @@ cli (root)
73
85
└── snapshot → config, macos
74
86
```
75
87
76
-
##CONVENTIONS
88
+
### Where to Look
77
89
78
-
-**Error wrapping**: `fmt.Errorf("context: %w", err)` — always wrap with context
79
-
-**UI output**: Use `ui.Header/Success/Error/Info/Warn/Muted` — never raw fmt for user-facing text
80
-
-**Command exec**: `system.RunCommand()` (interactive) or `system.RunCommandSilent()` (capture output)
81
-
-**Embedded data**: `//go:embed data/*.yaml` with `embed.FS`, loaded in `init()`
82
-
-**Testing**: Table-driven with testify/assert. Build tags for integration/e2e
83
-
-**Concurrency**: `sync.WaitGroup` with bounded workers (max 4 for brew)
84
-
-**Dry-run**: All destructive operations check `cfg.DryRun` first
85
-
-**Version string**: Default `"dev"` in `internal/cli/root.go` — injected via ldflags at build time, never edit manually
86
-
-**Config storage**: `~/.openboot/` directory for auth, state, snapshots
87
-
-**CLI backward compatibility**: All CLI changes (commands, flags, arguments) must maintain backward compatibility. Old syntax must continue to work when adding new features
88
-
89
-
## ANTI-PATTERNS
90
-
91
-
- No `as any` equivalent — no type assertion abuse
92
-
- No ignored errors (`_ = err`) in production code
93
-
- No `panic()` except `log.Fatalf` in `init()` for fatal config errors
94
-
- No hardcoded `~` paths — always `os.UserHomeDir()`
95
-
- No unbounded goroutines — always WaitGroup + max workers
96
-
- No direct stdout for styled text — always through `ui` package
> **Note:** The `\`\`\`` above is how triple backticks are shown inside a Markdown code block. In the actual `gh release edit` command, use real unescaped triple backticks (` ``` `).
168
-
169
174
**Rules:**
170
175
171
176
- Omit empty sections (no "Bug Fixes" if there are none)
172
177
- Write for **users**, not developers. No internal refactors, no test-only changes
173
178
-**Bold name**: 2–4 words max, noun form. Not a sentence.
174
-
-**Description**: ONE sentence, ~10–15 words max. User benefit only — no implementation details, no "how it works".
179
+
-**Description**: ONE sentence, ~10–15 words max. User benefit only — no implementation details.
175
180
- Include the CLI command at the end if it's a new/changed command
176
181
- Keep Installation and Binaries sections at the bottom (always)
0 commit comments