Documentation
¶
Overview ¶
Package hotreload watches forge.yaml for changes and applies safe updates to the running daemon without a restart.
Hot-reloadable settings:
- settings.poll_interval
- settings.smith_timeout
- settings.max_total_smiths
- settings.claude_flags
- settings.providers
- settings.smith_providers
- settings.max_ci_fix_attempts (applied immediately to lifecycle manager)
- settings.max_review_fix_attempts (applied immediately to lifecycle manager)
- settings.max_rebase_attempts (applied immediately to lifecycle manager)
- settings.copilot_combined_smith_warden (toggle combined mode at runtime)
- settings.copilot_warden_sample_rate (adjust sampling rate at runtime)
- notifications.* (all notification settings)
- anvils.<name>.auto_merge (takes effect on next ready-to-merge transition)
- anvils.<name>.max_smiths (changes to existing anvils' concurrency limit)
- anvils.<name>.path (changes to existing anvils' path; updates bellows and depcheck)
- anvils.* adding or removing anvil entries (updates bellows and depcheck)
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Callback ¶
Callback is called when config changes are detected and applied. oldCfg is the previous config, newCfg is the updated config.
type Watcher ¶
type Watcher struct {
// contains filtered or unexported fields
}
Watcher monitors the config file and applies safe changes.
func NewWatcher ¶
NewWatcher creates a config file watcher.
func (*Watcher) Start ¶
Start begins watching the config file. Blocks until Stop() or error.
We watch the parent directory instead of the file itself because many editors (and tools like Viper) save files via write-to-temp + rename. On Windows this can cause fsnotify to stop delivering events for the original file after the rename. Watching the directory catches Create/Rename events for the config filename regardless of how the file is written.