New user-facing features:
- `export connections <file>` writes a tabular dump of every wire pair:
connection, transform, left/right module/part/pin/signal/type/suspect,
mixed-types flag. Dispatch on extension: `.csv` (flat file) or `.ods`
(one sheet per connection). Any other extension shows an error and
writes nothing.
- Bare `export` (or dashboard `[x]`, or palette `export`) opens an
interactive file-picker dialog with a CSV/ODS toggle at the top.
Picking a filter rewrites the filename's extension. Last-used
directory and filename are remembered per-call-site.
- Two new CLI flags on the binary: `--source FILE` to run a script at
boot, `--restore FILE` to restore a snapshot at boot. Combinable.
Reusable infrastructure:
- `OdsWriter` (`src/imports/ods_writer.{hpp,cpp}`): minimal .ods writer
using libzip + pugixml (already in the build for the importer).
Multi-sheet workbook of string cells. ~180 lines, no new dep.
- Generic file-picker dialog (`screen_filedialog.cpp`): one Modal
reused for any "pick a path" interaction via
`OpenFileDialog(title, persist_key, default_filename, filters, cb)`.
Validates the picked extension against the filter whitelist;
unknown ones stay in the dialog with a status message. Persists
(dir, filename) per `persist_key`.
- Generic error modal (`screen_error.cpp`, `ShowError(msg)`): centred
red-titled popup, dismissable with Esc/Enter. Used by the export
failures (open-for-write, ODS save, unknown extension/kind);
ready for adoption elsewhere.
- Per-key path persistence (`SaveLastUsed`/`LoadLastUsed` in
`shell.cpp`): two-line file per key under the user-data dir.
- `UserDataDir()` extracted from the history path helper so the new
per-key persistence shares the same XDG/AppData logic.
- New help-screen topic "Export"; user-facing `doc/user/analysis.md`
gains an "Exporting" section; `DESIGN.md` gains a generics
section covering the dialog / error modal / persistence / ODS
writer; `DumpCommandsMd` now respects the `hidden` flag (the
`connect` alias no longer appears in the auto-gen reference).
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
4.2 KiB
essim — command reference
Auto-generated from the live command registry. Regenerate with
cmake --build build --target doc after adding or changing
commands; the binary itself is the single source of truth.
Keys global to the shell: Esc cancels a multi-step prompt or
leaves an interactive screen; Tab completes commands/paths
(top-level prompt) or cycles focus inside an interactive
screen; PageUp / PageDown scroll output by 10 lines,
Home / End jump to top / bottom; ↑ / ↓ walk command
history.
Interactive commands
dashboard (interactive)
open the dashboard (system overview)
No arguments. Notes
- bare form opens an interactive screen; inline form (all args) is scriptable
- not recorded by
script-saveand rejected bysource
explore (interactive)
browse modules → parts/signals/connections → details (interactive)
No arguments. Notes
- bare form opens an interactive screen; inline form (all args) is scriptable
- not recorded by
script-saveand rejected bysource
export (interactive)
export structured data to CSV (kinds: connections; bare form opens the file-picker dialog)
Arguments
kind [connections]filename (.csv)(Tab → path completion)
Notes
- bare form opens an interactive screen; inline form (all args) is scriptable
plug (interactive)
connect a part across two modules (interactive screen if no args)
Arguments
module1part1 (name or pattern)module2part2 (name or pattern)
Notes
- bare form opens an interactive screen; inline form (all args) is scriptable
set-connector-type (interactive)
tag a part's connector type for transform lookup
Arguments
modulepart (name or pattern)connector type (free string, e.g. vpx-bp, vpx-payload)
Notes
- bare form opens an interactive screen; inline form (all args) is scriptable
Other commands
analyze
detect signal groups (diff pairs, buses) and structural anomalies
No arguments.
clear
clear the visualization area
No arguments.
duplicate
clone a module under a new name (parts, pins, signals; no connections)
Arguments
source modulenew module name
Notes
- missing args trigger one prompt each
exit
leave essim (alias of quit)
No arguments.
help
list commands (or help <name> for one command's details)
Arguments
command name (optional)(Tab → command completion)
Notes
- no per-arg prompt: pass all args inline (or run bare for an empty-args path)
load
load a module from a netlist / pinout file (mentor, altium, ods)
Arguments
module namefilename(Tab → path completion)import type [mentor|altium|ods]
Notes
- missing args trigger one prompt each
new
create a new (empty) system; resets the script-save buffer and $vars
No arguments.
quit
leave essim
No arguments.
restore
replace the current system with a saved snapshot
Arguments
filename(Tab → path completion)
Notes
- missing args trigger one prompt each
save
write the current system snapshot to a file
Arguments
filename(Tab → path completion)
Notes
- missing args trigger one prompt each
script-save
write commands run since last 'new' as a replay-ready script
Arguments
filename(Tab → path completion)
Notes
- missing args trigger one prompt each
set
define a $variable for substitution in subsequent commands (no args = list defined vars)
Arguments
namevalue
Notes
- no per-arg prompt: pass all args inline (or run bare for an empty-args path)
set-signal-type
override the auto-detected signal type (power | gnd | other)
Arguments
modulesignal nametype [power|gnd|other]
Notes
- missing args trigger one prompt each
source
execute a file of commands line by line (interactive cmds rejected)
Arguments
filename(Tab → path completion)
Notes
- missing args trigger one prompt each
verify
check pin roles locally and signal-type consistency across bridged nets