fix(cli): diff row data + multi-form flag parser + Windows installer - #45
Merged
Merged
Conversation
Three operator-reported fixes bundled into one release because they all
surfaced in the same debug session:
1. 'deltix diff' crashed on every call with 'TypeError: rows.reduce is
not a function'. The server returns { fromRef, toRef, tables: [...] }
and the CLI passed 'diff' directly to printTable (which then called
.reduce on an object instead of an array). Pass diff.tables.
2. 'deltix log -n 5' mis-parsed '-n' as the repo name. The flag helper
parseFlagValue only matched '--name=value'. Rewrote it to accept all
three POSIX forms: --name=value, --name value, and -x value for
single-char short flags. flagValue for --password= and --from= now
use the same helper. 7 unit tests covering all three forms.
3. Windows users now get a one-liner installer too:
scripts/get-deltix-client.ps1 mirrors get-deltix-client.sh.
Detects AMD64/ARM64, downloads via Invoke-WebRequest, verifies SHA-256
via Get-FileHash, defaults to $HOME\.local\bin\deltix.exe,
-System flag auto-elevates via runas to C:\Program Files\Deltix.
Same VERSION= and INSTALL_DIR= env vars as the bash script.
Documented in the README Windows install section.
140 unit tests pass; lint clean.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Three operator-reported fixes bundled in one PR (they surfaced in the same debug session):
deltix diffcrashed with 'rows.reduce is not a function' on every call — server returns { fromRef, toRef, tables: [...] } and CLI passed 'diff' directly to printTable. Pass diff.tables.deltix log -n 5mis-parsed '-n' as the repo name. Rewrote parseFlagValue to accept --name=value, --name value, and -x value for single-char short flags.140 unit tests pass; lint clean.