(opts Options)
| 80 | } |
| 81 | |
| 82 | func newApp(opts Options) App { |
| 83 | cfg, cfgErr := config.Load(opts.ConfigPath) |
| 84 | a := App{ |
| 85 | opts: opts, |
| 86 | keys: defaultKeys(), |
| 87 | active: tabHome, |
| 88 | cfg: cfg, |
| 89 | cfgErr: cfgErr, |
| 90 | } |
| 91 | a.home = newHomeModel(&a) |
| 92 | a.profiles = newProfilesModel(&a) |
| 93 | a.scan = newScanModel(&a) |
| 94 | a.run = newRunModel(&a) |
| 95 | a.settings = newSettingsModel(&a) |
| 96 | a.help = newHelpModel(&a) |
| 97 | a.about = newAboutModel(&a) |
| 98 | return a |
| 99 | } |
| 100 | |
| 101 | // Init starts any background tick processes the screens need. |
| 102 | func (a App) Init() tea.Cmd { |
no test coverage detected