Skip to content

v2.0.0

Latest

Choose a tag to compare

@jim-collier jim-collier released this 26 Aug 20:06
· 65 commits to main since this release

Major version bump. Two things change compatibly for some edge cases (that aren't currently in use):

  • Field names now resolve their escapes, so "a\"b" and 'a"b' are one field where they used to be two, and the C++ veneer's read_datetime returns the structured value every other binding's does, with the text form moving to read_datetime_str.

  • Canonical output also moves for a few things where the old output lost something or wouldn't settle, so a file reformatted by 2.0 can differ from the same file reformatted by 1.2.

Go consumers import github.com/jim-collier/shcl/source/go/v2; Rust and Python consumers change a version constraint and nothing else.

New: a file tier in every binding - load_file/save_file beside the text entry points, an atomic temp-file-and-rename write, and a load status that tells missing apart from unreadable and from parsed-with-errors. On top of it a save gate: save_file refuses to write a document that lost content on load, and save_file_lossy is the stated override. Also AuthoredName, the _or convenience tier, reopen: true in schemas, a man page and bash/zsh completions, --lossy and -v on the CLI, set --write creating a file that is not there yet, and installers that can uninstall. Windows executables carry the icon and version metadata, and release builds are reproducible on the pinned toolchain, so the published checksums can be re-derived rather than trusted.

Parsing takes less time and memory in every binding. A 100 MiB document went from 3.8 GB to 2.1 GB in Rust and from 7.0 GB to 3.0 GB in C, with byte-identical output.

Fixed:

  • Several round-trip bugs (a whitespace-only line inside a raw block

  • A raw block with no non-blank line growing an indent level on every pass

  • A trailing carriage-return run, merged output that was not a formatter fixpoint

  • The C binding following the host locale for numbers

  • The three ports disagreeing with the reference on a rare quoted-selector fallback

  • set --write deleting unreadable lines in silence

  • Windows in-place writes dropping ACLs and alternate data streams

  • The PowerShell wrapper needing PowerShell 7 (not a bug per-se).

Removed: go install .../source/go/cmd/shcl. The Go module is the library alone now; the Rust binary is the CLI this project distributes, and it is what the packages, the installers and cargo install shcl all deliver.

Releases are signed. shcl-2.0.0-sha256sums.txt.sig is a detached signature over the checksums file, and both install scripts verify it before trusting any checksum. The public key is at shcl-signing.pub in the repo.

See the changelog for the full list of changes since v1.2.0.