@@ -62,30 +62,38 @@ var presetsYAML embed.FS
6262//go:embed data/screen-recording-packages.yaml
6363var screenRecordingYAML embed.FS
6464
65+ // Config holds all configuration for a single openboot run.
66+ //
67+ // TODO(future): split into InstallOptions (input, read-only) and
68+ // InstallState (runtime, mutable) once the call-sites are ready.
6569type Config struct {
66- Version string
67- Preset string
68- Silent bool
69- DryRun bool
70- Update bool
71- Shell string
72- Macos string
73- Dotfiles string
74- GitName string
75- GitEmail string
76- SelectedPkgs map [string ]bool
77- OnlinePkgs []Package
78- SnapshotTaps []string
79- User string
80- RemoteConfig * RemoteConfig
81- PackagesOnly bool
82-
83- SnapshotGit * SnapshotGitConfig
84- SnapshotMacOS []RemoteMacOSPref
85- SnapshotDotfiles string
86- DotfilesURL string
87- PostInstall string
88- AllowPostInstall bool
70+ // --- Input (set by flags/env before run) ---
71+
72+ Version string // injected via -ldflags at build time
73+ Preset string // -p / OPENBOOT_PRESET
74+ User string // -u / OPENBOOT_USER
75+ DryRun bool // --dry-run
76+ Silent bool // -s / CI mode
77+ PackagesOnly bool // --packages-only
78+ Update bool // --update
79+ Shell string // --shell (install|skip)
80+ Macos string // --macos (configure|skip)
81+ Dotfiles string // --dotfiles (clone|link|skip)
82+ GitName string // OPENBOOT_GIT_NAME (silent mode)
83+ GitEmail string // OPENBOOT_GIT_EMAIL (silent mode)
84+ PostInstall string // --post-install
85+ AllowPostInstall bool // --allow-post-install
86+ DotfilesURL string // from remote config
87+
88+ // --- Runtime state (populated during install) ---
89+
90+ SelectedPkgs map [string ]bool // set by UI package selector
91+ OnlinePkgs []Package // fetched from packages API
92+ SnapshotTaps []string // from snapshot capture
93+ RemoteConfig * RemoteConfig // fetched from openboot.dev at startup
94+ SnapshotGit * SnapshotGitConfig // from snapshot capture
95+ SnapshotMacOS []RemoteMacOSPref // from snapshot capture
96+ SnapshotDotfiles string // from snapshot capture
8997}
9098
9199type SnapshotGitConfig struct {
0 commit comments