configtui

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 14, 2026 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Overview

Package configtui is a standalone Bubble Tea terminal Config Builder/Editor that mirrors the web Config Builder (web/configbuilder). It is reflection- driven: it walks config.Config so every field is editable automatically (it cannot drift from the schema), with a metadata table supplying the web-like polish — labels, help, select options, Hz formatting, fieldset grouping and the AdvancedJSON long-tail. It operates on the local filesystem via the config package directly (no daemon, no browser).

The labels / help / select options / Hz+freq-list flags all come from the shared registry in internal/configbuilder (sections.go + fieldmeta.go) so the terminal builder and the web builder present identical help from one source.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Model

type Model struct {
	// contains filtered or unexported fields
}

Model is the standalone terminal Config Builder.

func New

func New(dirs []string, rrAuth radioreference.Auth, parse ParseFunc, initialPath string) Model

New builds the model. dirs is the allowed config directories; rrAuth the RadioReference creds; parse the injected import parser; initialPath an optional file to open at start.

func (Model) Init

func (m Model) Init() tea.Cmd

func (Model) Update

func (m Model) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (Model) View

func (m Model) View() string

type ParseFunc

type ParseFunc func(path, kind string) (config.SystemConfig, []configbuilder.TalkgroupCSVRow, error)

ParseFunc parses one PDF/CSV import file (kind "pdf"/"csv") into a parsed system, injected by the cmd wrapper which owns the parser. Returns the system config + talkgroup rows to fold into the draft.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL