Python Textual TUI that mirrors the core workflows from the VS Code EDA extension:
- Connect to an EDA target with Keycloak auth
- VS Code-style left explorer tree (Dashboards + Resources + Kubernetes)
- Target selection through a modal (
Ctrl+R) - Stream-driven updates (no manual refresh buttons)
- Load selected resource to YAML editor, then apply / dry-run / add-to-basket
- Commit/dry-run/discard transaction basket (
Transactionsuser storage file) - Transaction details, revert, restore
- Deviation accept/reject/reject-all
- Keyboard-first shortcuts with context-aware footer hints
Ctrl+Gexplorer tree focusCtrl+Ddashboard focus (query input forQueries, table otherwise)Ctrl+Leditor focusCtrl+F2explorer filter focusCtrl+F6/Ctrl+F7expand/collapse explorerCtrl+F8toggle activity logCtrl+Ropen targetsCtrl+Jopen jump launcherCtrl+F1open keyboard help for current contextCtrl+F9open omni searchCtrl+F10open resource browserCtrl+F3details actionCtrl+Shift+F3primary actionCtrl+Shift+F6secondary actionCtrl+Shift+F7tertiary action1..9and0trigger the currently visible footer actions- Explorer ergonomics:
h/j/k/laliases (h/lcollapse-expand,j/kmove) - Dashboard table ergonomics:
j/k/h/laliases for table movementHome/Endjump to first/last row,PageUp/PageDownjump by 12 rowsEnteropens row details for standard dashboards- Pods dashboard:
Left/RightorTab/Shift+Tabchoose inline action column,Enterruns it
eda_tui/core/: runtime config, env flags, paths, logging helpers.eda_tui/domain/: domain models and target loading.eda_tui/services/api/: API client, API models, and stream transport.eda_tui/services/repository.py: service-level repository boundary.eda_tui/ui/screens/: dashboard + modal screen components.eda_tui/ui/widgets/: reusable UI widgets/builders.eda_tui/ui/actions/: tree/connection action handlers.eda_tui/ui/state/: focused UI state models.eda_tui/ui/styles/app.tcss: Textual CSS.eda_tui/app.pyandeda_tui/client.py: compatibility facades for existing entrypoints/imports.
cd /root/projects/vscode-eda/eda-textual-tui
uv sync
uv run eda-tuicurl eda.dev/uvx | sh -s -- https://github.com/eda-labs/eda-tui/archive/refs/heads/main.zipRun these commands locally before committing:
uv run ruff format .
uv run ruff check .
uv run pylint eda_tuiOptional auto-fix pass:
uv run ruff check --fix .The UI now uses Nerd Font glyphs for explorer nodes, dashboard labels, and action buttons.
- Recommended: install a Nerd Font in your terminal profile (for example
JetBrainsMono Nerd Font). - Project: https://github.com/ryanoasis/nerd-fonts
- Downloads: https://github.com/ryanoasis/nerd-fonts/releases/latest
If you need plain ASCII labels (for unsupported terminals), disable icons:
EDA_TUI_USE_NERD_FONTS=0 uv run eda-tuiThe app can load targets from:
./targets.jsonwhen running from a checked-out repo~/.config/eda-tui/targets.jsonfor installed usage (or$EDA_TUI_TARGETS_FILEoverride)- Environment variables (
EDA_TUI_TARGET_URL,EDA_TUI_EDA_USERNAME,EDA_TUI_CLIENT_ID, ...), sotargets.jsonis optional
Expected file shape is intentionally close to the extension:
{
"https://eda.example.local": {
"context": "kubernetes-admin@kubernetes",
"edaUsername": "admin",
"clientId": "eda",
"kcUsername": "admin",
"skipTlsVerify": true,
"coreNamespace": "eda-system"
}
}Supported keys per target:
contextedaUsernameclientIdkcUsernameskipTlsVerifycoreNamespace
Notes:
- Keep secrets out of inline target fields. Store credentials from the target modal (
Ctrl+R). - Legacy inline secret keys (
edaPassword,clientSecret,kcPassword) are still read, but save/update flows remove them. - If
clientSecretis blank but Keycloak admin credentials are available, the app can fetch the client secret from Keycloak. - Explorer data updates via WebSocket + SSE stream registrations.
- The app no longer writes
.last-target.json; it only auto-connects when exactly one target is configured.
Run the app:
uv run eda-tuiIf no targets exist, the app opens the target modal automatically. In that modal you can:
- Create/edit target metadata
- Select Kubernetes context from kubeconfig contexts
- Save target config
- Delete targets
- Credentials are always saved inside
~/.eda-tui/targets.jsonwhen provided - Retrieve client secret from Keycloak (URL + KC admin credentials)
- Connect immediately
(eda-tui with no subcommand also runs the app.)
For non-interactive automation you can provide an access token at runtime:
export EDA_TUI_TOKEN='...'
# or
export EDA_TUI_TOKEN_FILE=/path/to/token.txtTokens are read at runtime and are not persisted by the app.
For fileless target metadata you can also set:
export EDA_TUI_TARGET_URL=https://eda.example.local
export EDA_TUI_EDA_USERNAME=admin
export EDA_TUI_CLIENT_ID=eda
export EDA_TUI_CREDENTIALS_REF=eda-example-local