Add injection backends

This commit is contained in:
Thales Maciel 2026-02-06 11:50:30 -03:00
parent a7f50fed75
commit 9ee301fbeb
7 changed files with 290 additions and 4 deletions

View file

@ -21,6 +21,7 @@ type Config struct {
WhisperTimeoutSec int `toml:"whisper_timeout_sec"`
SegmentSec int `toml:"segment_sec"`
Streaming bool `toml:"streaming"`
InjectionBackend string `toml:"injection_backend"`
}
func DefaultPath() string {
@ -40,6 +41,7 @@ func Defaults() Config {
WhisperTimeoutSec: 300,
SegmentSec: 5,
Streaming: false,
InjectionBackend: "clipboard",
}
}
@ -108,6 +110,9 @@ func applyEnv(cfg *Config) {
if v := os.Getenv("LEL_HOTKEY"); v != "" {
cfg.Hotkey = v
}
if v := os.Getenv("LEL_INJECTION_BACKEND"); v != "" {
cfg.InjectionBackend = v
}
}
func parseBool(v string) bool {