YAY 2.0.0
Release notes, October 29, 2026
Only binyay, the yay command, moves to 2.0.0.
libyay and the other ports do not change, and stay at
1.1.1. The format is the same: every document reads
as it did. For the format itself, see Yet Another YAML.
Each example below shows a command and what 1.1.1 and 2.0.0 print for it,
pasted from a run of the two releasesโ yay.
Install
brew install kriskowal/yippee/yay # Homebrew (via tap): 2.0.0
Or download yay for your platform from the
v2.0.0 release
on GitHub:
- macOS on Apple silicon: yay-aarch64-apple-darwin.tar.gz
- macOS on Intel: yay-x86_64-apple-darwin.tar.gz
- Linux on x86-64: yay-x86_64-unknown-linux-gnu.tar.gz, or statically linked with musl: yay-x86_64-unknown-linux-musl.tar.gz
- Linux on ARM64: yay-aarch64-unknown-linux-gnu.tar.gz
- Windows on x86-64: yay-x86_64-pc-windows-msvc.zip
Packages: 2.0.0 is published, with the
change in these notes: the binyay package on npm, with its five
platform packages, and the binyay crate on crates.io. The
libyay packages stay at 1.1.1.
npm install -g binyay # the yay command, from npm
cargo install binyay # the yay command, from crates.io
The formatting check is --check -t
yay --canonical is gone. It checked that yay
would write a document unchanged, which makes it a formatting check, like
gofmt -l. It did not make a document canonical: two documents
with the same value can both pass and still differ in key order, quoting or
comments. So the check is now spelled with the format it writes, and the
docs call a document that passes โformattedโ.
--check means one of two things:
yay --check [-f F] file, without-t: check that the input is valid, strict YAY by default. Unchanged.yay --check [-f F] -t T file: read the input asF, write it asT, and pass only if the output is the same bytes as the input; otherwise name the first line that differs.-fdefaults to strictyay.
summary: `
First paragraph.
author: "Ada Lovelace"
1.1.1
$ yay --canonical summary.yay
summary.yay: not canonical at line 3: expected a blank line (after a block string)
$ yay --check -t yay summary.yay
summary.yay: ok
2.0.0
$ yay --canonical summary.yay
Error: Unknown option: --canonical
$ yay --check -t yay summary.yay
summary.yay: not formatted at line 3: expected a blank line (after a block string)
Note the second command: 1.1.1 ignored -t under
--check and checked only that the document was valid, so a script
that already passes -t yay starts failing on documents that are
valid but not formatted. yay -w summary.yay rewrites one in the
form the check expects.
Migration
# 1.1.1 2.0.0
yay --canonical F yay --check -t yay F
yay --canonical -f meh F yay --check -f meh -t yay F
yay --canonical -f yd F yay --check -f yd -t yd F
yay --canonical -f md F yay --check -f md -t md F
Pairs that cannot pass are refused
Only a pair whose output can equal its input is allowed: -f yay
or meh with -t yay, and -f md or
yd with -t md or yd. Any other pair is
an error, JSON to JSON included, since that writer sorts keys and respells
numbers.
{"b": 1, "a": 2}
1.1.1
$ yay --check -f json -t json data.json
data.json: ok
2.0.0
$ yay --check -f json -t json data.json
Error: --check -f json -t json: json output is never the same bytes as json input
Hint: --check with -t compares the output with the input; it takes -f yay or meh with -t yay, and -f md or yd with -t md or yd. Without -t, --check checks validity.
A missing final newline says so
A document whose only difference is a missing newline at the end is now
reported as that, where 1.1.1 showed two lines that looked the same. Here is
summary.yay, formatted, without its final newline:
1.1.1
$ yay --canonical nonl.yay
nonl.yay: not canonical at line 4: expected "author: \"Ada Lovelace\"", found "author: \"Ada Lovelace\""
2.0.0
$ yay --check -t yay nonl.yay
nonl.yay: not formatted at line 4: the last line must end with a newline
The full change is in CHANGELOG.md and the CLI reference.