Skip to content

Draft: Basic CLI Export Support#437

Draft
m10653 wants to merge 3 commits into
Mechanical-Advantage:mainfrom
m10653:cli-support
Draft

Draft: Basic CLI Export Support#437
m10653 wants to merge 3 commits into
Mechanical-Advantage:mainfrom
m10653:cli-support

Conversation

@m10653
Copy link
Copy Markdown
Contributor

@m10653 m10653 commented Nov 25, 2025

Very rough start to add command line support to Advantage Scope. Right now just focusing on merging and exporting files. However in the future plan on adding the ability to specify what logs to open along with what template/view to use. This would enable the creation of desktop shortcuts for different layouts/views as well as possibly adding file handlers advantage scope compatible log files.

Currently the following pr has quite a few issues. The main one being how I am handling the WASM indexer for wpilog files. I had a lot of issues generating a valid wasm binary that would work for both node and web scopes, so a quick work around was to compile it twice with different command line args.

Architecturally right now log loading code is highly coupled to electron as a lot of the logic exists within the web workers. I played around a bit with breaking this off into FileLoader classes, although this breaks down a little bit with progress updates, wasm, as well as the lazy loading done with wpilogs (field loading logic is handled within the historical log record class)

Example Command line args

# Additional --inputs can be chained to merge logs together
npm start -- convert --input ~/Downloads/example.wpilog --output test-1.wpilog --format wpilog
# or
scopebin.exe convert --input ~/Downloads/example.wpilog --output test-1.wpilog --format wpilog

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant