Run starts the Bubble Tea program. Blocking; returns when the user quits.
(opts Options)
| 73 | |
| 74 | // Run starts the Bubble Tea program. Blocking; returns when the user quits. |
| 75 | func Run(opts Options) error { |
| 76 | app := newApp(opts) |
| 77 | p := tea.NewProgram(app, tea.WithAltScreen(), tea.WithMouseCellMotion()) |
| 78 | _, err := p.Run() |
| 79 | return err |
| 80 | } |
| 81 | |
| 82 | func newApp(opts Options) App { |
| 83 | cfg, cfgErr := config.Load(opts.ConfigPath) |