diff --git a/CHANGELOG.md b/CHANGELOG.md index 380ab44a..3491ced5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,7 @@ once it reaches a published 0.1.0 release. ### Fixed +- [S-155] A value spec written as one delimited alternation of literal values (`--compression=(xz|none|auto)`, `--crate-type `, argparse's own `{c,java,ruby,tcl}`) now attaches as that flag's choices, instead of rendering as one opaque placeholder (`mandible grub-mkimage`, `mandible rustc`, `mandible tclobjnew-bpfcc`). - `xtask sweep-diff` now reports subcommand-count gains and losses per tool, separately from flags, so an invented subcommand row no longer passes as a clean sweep. - `xtask detector calibrate` now prints `NOT EVALUABLE` instead of `DOES NOT PASS` for a detector whose family has zero labelled members in the audit seed, so a legitimate gap in the sample is no longer reported as a failing detector. - [S-149] A bare-word block opening on a centered ALL-CAPS group label no longer ends before reading a single real row beneath it (`mandible fail2ban-client`). @@ -40,6 +41,9 @@ once it reaches a published 0.1.0 release. - [S-151] A usage form whose leading word names another program now renders under the tool's own name, so `mandible gcc-ranlib-13` shows `gcc-ranlib-13 [options] archive` instead of repeating `/usr/bin/ranlib`, and `mandible perlthanks` gains the usage section it had none of. - [S-142] A `SYNTAX:` label glued straight to the program name, and a usage continuation carrying an open `[` to column zero, are both read now, so `mandible mksquashfs` and `mandible sqfstar` show a real usage line and their `FILESYSTEM` positional instead of the whole synopsis as description prose (#143). - [S-171] A numbered `source1 source2 ...` pair ahead of a later required operand no longer drops, so `mandible mksquashfs` shows its `source` positional alongside `FILESYSTEM`. +- [S-157] A single-dash long option's bare-word value name inside a no-double-dash table now survives instead of reading as the first word of the description, so `mandible Xvfb` shows `-audit int` and `-fp string`, and `mandible mksquashfs`/`mandible sqfstar` show `-Xstrategy` and `-Xbcj` with their comma-separated value lists. +- [S-158] A value spec that glues a bracket-optional group directly onto a required angle placeholder now keeps the whole run, so `mandible rustc` shows `-L`'s `[=]` and `--emit`'s `[=]` in full instead of losing the half that doesn't open the run. +- [S-160] A value spec that swallowed its own alias run's trailing comma no longer hides the spelling behind it, so `mandible biolatpcts-bpfcc` shows `-p, --pcts` instead of a lone `-p`. ## [0.7.0] - 2026-09-05 diff --git a/corpus/Xvfb/audit-seed10/expected.snap b/corpus/Xvfb/audit-seed10/expected.snap new file mode 100644 index 00000000..68dd3d81 --- /dev/null +++ b/corpus/Xvfb/audit-seed10/expected.snap @@ -0,0 +1,494 @@ +name: Xvfb +description: 'Unrecognized option: --help use: X [:] [option] -a # default pointer acceleration (factor) -ac disable access control restrictions -audit int set audit trail level -auth file select authorization file -br create root window with black background +bs enable any backing store support -bs disable any backing store support +byteswappedclients Allow clients with endianess different to that of the server -byteswappedclients Prohibit clients with endianess different to that of the server -c turns off key-click c # key-click volume (0-100) -cc int default color visual class -nocursor disable the cursor -core generate core dump on fatal error -displayfd fd file descriptor to write display number to when ready to connect -dpi int screen resolution in dots per inch -dpms disables VESA DPMS monitor control -deferglyphs [none|all|16] defer loading of [no|all|16-bit] glyphs -f # bell base (0-100) -fakescreenfps # fake screen default fps (1-600) -fp string default font path -help prints message with these options +iglx Allow creating indirect GLX contexts -iglx Prohibit creating indirect GLX contexts (default) -I ignore all remaining arguments -ld int limit data space to N Kb -lf int limit number of open files to N -ls int limit stack space to N Kb -nolock disable the locking mechanism -maxclients n set maximum number of clients (power of two) -nolisten string don''t listen on protocol -listen string listen on protocol -noreset don''t reset after last client exists -background [none] create root window with no background -reset reset after last client exists -p # screen-saver pattern duration (minutes) -pn accept failure to listen on all ports -nopn reject failure to listen on all ports -r turns off auto-repeat r turns on auto-repeat -render [default|mono|gray|color] set render color alloc policy -retro start with classic stipple and cursor -s # screen-saver timeout (minutes) -seat string seat to run on -t # default pointer threshold (pixels/t) -terminate [delay] terminate at server reset (optional delay in sec) -tst disable testing extensions ttyxx server started from init on /dev/ttyxx v video blanking for screen-saver -v screen-saver without video blanking -wr create root window with white background -maxbigreqsize set maximal bigrequest size +xinerama Enable XINERAMA extension -xinerama Disable XINERAMA extension -dumbSched Disable smart scheduling and threaded input, enable old behavior -schedInterval int Set scheduler interval in msec -sigstop Enable SIGSTOP based startup +extension name Enable extension -extension name Disable extension -query host-name contact named host for XDMCP -broadcast broadcast for XDMCP -multicast [addr [hops]] IPv6 multicast for XDMCP -indirect host-name contact named host for indirect XDMCP -port port-num UDP port number to send messages to -from local-address specify the local address to connect from -once Terminate server after one session -class display-class specify display class to send in manage -cookie xdm-auth-bits specify the magic cookie for XDMCP -displayID display-id manufacturer display ID for request [+-]accessx [ timeout [ timeout_mask [ feedback [ options_mask] ] ] ] -ardelay set XKB autorepeat delay -arinterval set XKB autorepeat interval -screen scrn WxHxD set screen''s width, height, depth -pixdepths list-of-int support given pixmap depths +/-render turn on/off RENDER extension support(default on) -linebias n adjust thin line pixelization -blackpixel n pixel value for black -whitepixel n pixel value for white -fbdir directory put framebuffers in mmap''ed files in directory -shmem put framebuffers in shared memory (EE) Fatal server error: (EE) Unrecognized option: --help (EE)' +flags: +- spellings: + - -a + value_name: '#' + value_kind: Required + group: 'use: X [:] [option]' + description: default pointer acceleration (factor) + provenance: + sources: + - help-text +- spellings: + - -ac + group: 'use: X [:] [option]' + description: disable access control restrictions + provenance: + sources: + - help-text +- spellings: + - -audit + value_name: int + value_kind: Required + group: 'use: X [:] [option]' + description: set audit trail level + provenance: + sources: + - help-text +- spellings: + - -auth + value_name: file + value_kind: Required + group: 'use: X [:] [option]' + description: select authorization file + provenance: + sources: + - help-text +- spellings: + - -br + group: 'use: X [:] [option]' + description: create root window with black background + provenance: + sources: + - help-text +- spellings: + - -bs + description: disable any backing store support + provenance: + sources: + - help-text +- spellings: + - -byteswappedclients + description: Prohibit clients with endianess different to that of the server + provenance: + sources: + - help-text +- spellings: + - -c + description: turns off key-click + provenance: + sources: + - help-text +- spellings: + - -cc + description: default color visual class + provenance: + sources: + - help-text +- spellings: + - -nocursor + description: disable the cursor + provenance: + sources: + - help-text +- spellings: + - -core + description: generate core dump on fatal error + provenance: + sources: + - help-text +- spellings: + - -displayfd + value_name: fd + value_kind: Required + description: file descriptor to write display number to when ready to connect + provenance: + sources: + - help-text +- spellings: + - -dpi + value_name: int + value_kind: Required + description: screen resolution in dots per inch + provenance: + sources: + - help-text +- spellings: + - -dpms + description: disables VESA DPMS monitor control + provenance: + sources: + - help-text +- spellings: + - -deferglyphs + description: defer loading of [no|all|16-bit] glyphs + provenance: + sources: + - help-text +- spellings: + - -f + value_name: '#' + value_kind: Required + description: bell base (0-100) + provenance: + sources: + - help-text +- spellings: + - -fakescreenfps + description: fake screen default fps (1-600) + provenance: + sources: + - help-text +- spellings: + - -fp + value_name: string + value_kind: Required + description: default font path + provenance: + sources: + - help-text +- spellings: + - -help + description: prints message with these options + provenance: + sources: + - help-text +- spellings: + - -iglx + description: Prohibit creating indirect GLX contexts (default) + provenance: + sources: + - help-text +- spellings: + - -I + description: ignore all remaining arguments + provenance: + sources: + - help-text +- spellings: + - -ld + value_name: int + value_kind: Required + description: limit data space to N Kb + provenance: + sources: + - help-text +- spellings: + - -lf + value_name: int + value_kind: Required + description: limit number of open files to N + provenance: + sources: + - help-text +- spellings: + - -ls + value_name: int + value_kind: Required + description: limit stack space to N Kb + provenance: + sources: + - help-text +- spellings: + - -nolock + description: disable the locking mechanism + provenance: + sources: + - help-text +- spellings: + - -maxclients + value_name: n + value_kind: Required + description: set maximum number of clients (power of two) + provenance: + sources: + - help-text +- spellings: + - -nolisten + value_name: string + value_kind: Required + description: don't listen on protocol + provenance: + sources: + - help-text +- spellings: + - -listen + value_name: string + value_kind: Required + description: listen on protocol + provenance: + sources: + - help-text +- spellings: + - -noreset + description: don't reset after last client exists + provenance: + sources: + - help-text +- spellings: + - -background + value_name: '[none]' + value_kind: Optional + description: create root window with no background + provenance: + sources: + - help-text +- spellings: + - -reset + description: reset after last client exists + provenance: + sources: + - help-text +- spellings: + - -p + value_name: '#' + value_kind: Required + description: screen-saver pattern duration (minutes) + provenance: + sources: + - help-text +- spellings: + - -pn + description: accept failure to listen on all ports + provenance: + sources: + - help-text +- spellings: + - -nopn + description: reject failure to listen on all ports + provenance: + sources: + - help-text +- spellings: + - -r + description: turns off auto-repeat + provenance: + sources: + - help-text +- spellings: + - -render + description: set render color alloc policy + provenance: + sources: + - help-text +- spellings: + - -retro + description: start with classic stipple and cursor + provenance: + sources: + - help-text +- spellings: + - -s + value_name: '#' + value_kind: Required + description: screen-saver timeout (minutes) + provenance: + sources: + - help-text +- spellings: + - -seat + value_name: string + value_kind: Required + description: seat to run on + provenance: + sources: + - help-text +- spellings: + - -t + value_name: '#' + value_kind: Required + description: default pointer threshold (pixels/t) + provenance: + sources: + - help-text +- spellings: + - -terminate + value_name: '[delay]' + value_kind: Optional + description: terminate at server reset (optional delay in sec) + provenance: + sources: + - help-text +- spellings: + - -tst + description: disable testing extensions + provenance: + sources: + - help-text +- spellings: + - -v + description: screen-saver without video blanking + provenance: + sources: + - help-text +- spellings: + - -wr + description: create root window with white background + provenance: + sources: + - help-text +- spellings: + - -maxbigreqsize + description: set maximal bigrequest size + provenance: + sources: + - help-text +- spellings: + - -xinerama + description: Disable XINERAMA extension + provenance: + sources: + - help-text +- spellings: + - -dumbSched + description: Disable smart scheduling and threaded input, enable old behavior + provenance: + sources: + - help-text +- spellings: + - -schedInterval + value_name: int + value_kind: Required + description: Set scheduler interval in msec + provenance: + sources: + - help-text +- spellings: + - -sigstop + description: Enable SIGSTOP based startup + provenance: + sources: + - help-text +- spellings: + - -extension + value_name: name + value_kind: Required + description: 'Disable extension Only the following extensions can be run-time enabled/disabled: Generic Event Extension MIT-SHM XTEST SECURITY XINERAMA XFIXES RENDER RANDR COMPOSITE DAMAGE MIT-SCREEN-SAVER DOUBLE-BUFFER RECORD DPMS X-Resource XVideo XVideo-MotionCompensation SELinux GLX' + provenance: + sources: + - help-text +- spellings: + - -query + value_name: host-name + value_kind: Required + description: contact named host for XDMCP + provenance: + sources: + - help-text +- spellings: + - -broadcast + description: broadcast for XDMCP + provenance: + sources: + - help-text +- spellings: + - -multicast + description: IPv6 multicast for XDMCP + provenance: + sources: + - help-text +- spellings: + - -indirect + value_name: host-name + value_kind: Required + description: contact named host for indirect XDMCP + provenance: + sources: + - help-text +- spellings: + - -port + value_name: port-num + value_kind: Required + description: UDP port number to send messages to + provenance: + sources: + - help-text +- spellings: + - -from + value_name: local-address + value_kind: Required + description: specify the local address to connect from + provenance: + sources: + - help-text +- spellings: + - -once + description: Terminate server after one session + provenance: + sources: + - help-text +- spellings: + - -class + value_name: display-class + value_kind: Required + description: specify display class to send in manage + provenance: + sources: + - help-text +- spellings: + - -cookie + value_name: xdm-auth-bits + value_kind: Required + description: specify the magic cookie for XDMCP + provenance: + sources: + - help-text +- spellings: + - -displayID + value_name: display-id + value_kind: Required + description: manufacturer display ID for request + provenance: + sources: + - help-text +- spellings: + - -ardelay + group: enable/disable accessx key sequences + description: set XKB autorepeat delay + provenance: + sources: + - help-text +- spellings: + - -arinterval + group: enable/disable accessx key sequences + description: set XKB autorepeat interval + provenance: + sources: + - help-text +- spellings: + - -screen + group: enable/disable accessx key sequences + description: set screen's width, height, depth + provenance: + sources: + - help-text +- spellings: + - -pixdepths + group: enable/disable accessx key sequences + provenance: + sources: + - help-text +- spellings: + - -linebias + value_name: n + value_kind: Required + description: adjust thin line pixelization + provenance: + sources: + - help-text +- spellings: + - -blackpixel + value_name: n + value_kind: Required + description: pixel value for black + provenance: + sources: + - help-text +- spellings: + - -whitepixel + value_name: n + value_kind: Required + description: pixel value for white + provenance: + sources: + - help-text +- spellings: + - -fbdir + value_name: directory + value_kind: Required + description: put framebuffers in mmap'ed files in directory + provenance: + sources: + - help-text +- spellings: + - -shmem + description: put framebuffers in shared memory + provenance: + sources: + - help-text +provenance: + sources: + - help-text + confidence: 0.5 +children_filled: true diff --git a/corpus/Xvfb/audit-seed10/help.stderr.txt b/corpus/Xvfb/audit-seed10/help.stderr.txt new file mode 100644 index 00000000..a93cedc5 --- /dev/null +++ b/corpus/Xvfb/audit-seed10/help.stderr.txt @@ -0,0 +1,107 @@ +Unrecognized option: --help +use: X [:] [option] +-a # default pointer acceleration (factor) +-ac disable access control restrictions +-audit int set audit trail level +-auth file select authorization file +-br create root window with black background ++bs enable any backing store support +-bs disable any backing store support ++byteswappedclients Allow clients with endianess different to that of the server +-byteswappedclients Prohibit clients with endianess different to that of the server +-c turns off key-click +c # key-click volume (0-100) +-cc int default color visual class +-nocursor disable the cursor +-core generate core dump on fatal error +-displayfd fd file descriptor to write display number to when ready to connect +-dpi int screen resolution in dots per inch +-dpms disables VESA DPMS monitor control +-deferglyphs [none|all|16] defer loading of [no|all|16-bit] glyphs +-f # bell base (0-100) +-fakescreenfps # fake screen default fps (1-600) +-fp string default font path +-help prints message with these options ++iglx Allow creating indirect GLX contexts +-iglx Prohibit creating indirect GLX contexts (default) +-I ignore all remaining arguments +-ld int limit data space to N Kb +-lf int limit number of open files to N +-ls int limit stack space to N Kb +-nolock disable the locking mechanism +-maxclients n set maximum number of clients (power of two) +-nolisten string don't listen on protocol +-listen string listen on protocol +-noreset don't reset after last client exists +-background [none] create root window with no background +-reset reset after last client exists +-p # screen-saver pattern duration (minutes) +-pn accept failure to listen on all ports +-nopn reject failure to listen on all ports +-r turns off auto-repeat +r turns on auto-repeat +-render [default|mono|gray|color] set render color alloc policy +-retro start with classic stipple and cursor +-s # screen-saver timeout (minutes) +-seat string seat to run on +-t # default pointer threshold (pixels/t) +-terminate [delay] terminate at server reset (optional delay in sec) +-tst disable testing extensions +ttyxx server started from init on /dev/ttyxx +v video blanking for screen-saver +-v screen-saver without video blanking +-wr create root window with white background +-maxbigreqsize set maximal bigrequest size ++xinerama Enable XINERAMA extension +-xinerama Disable XINERAMA extension +-dumbSched Disable smart scheduling and threaded input, enable old behavior +-schedInterval int Set scheduler interval in msec +-sigstop Enable SIGSTOP based startup ++extension name Enable extension +-extension name Disable extension + Only the following extensions can be run-time enabled/disabled: + Generic Event Extension + MIT-SHM + XTEST + SECURITY + XINERAMA + XFIXES + RENDER + RANDR + COMPOSITE + DAMAGE + MIT-SCREEN-SAVER + DOUBLE-BUFFER + RECORD + DPMS + X-Resource + XVideo + XVideo-MotionCompensation + SELinux + GLX +-query host-name contact named host for XDMCP +-broadcast broadcast for XDMCP +-multicast [addr [hops]] IPv6 multicast for XDMCP +-indirect host-name contact named host for indirect XDMCP +-port port-num UDP port number to send messages to +-from local-address specify the local address to connect from +-once Terminate server after one session +-class display-class specify display class to send in manage +-cookie xdm-auth-bits specify the magic cookie for XDMCP +-displayID display-id manufacturer display ID for request +[+-]accessx [ timeout [ timeout_mask [ feedback [ options_mask] ] ] ] + enable/disable accessx key sequences +-ardelay set XKB autorepeat delay +-arinterval set XKB autorepeat interval +-screen scrn WxHxD set screen's width, height, depth +-pixdepths list-of-int support given pixmap depths ++/-render turn on/off RENDER extension support(default on) +-linebias n adjust thin line pixelization +-blackpixel n pixel value for black +-whitepixel n pixel value for white +-fbdir directory put framebuffers in mmap'ed files in directory +-shmem put framebuffers in shared memory +(EE) +Fatal server error: +(EE) Unrecognized option: --help +(EE) diff --git a/corpus/Xvfb/audit-seed10/help.txt b/corpus/Xvfb/audit-seed10/help.txt new file mode 100644 index 00000000..e69de29b diff --git a/corpus/Xvfb/audit-seed10/meta.toml b/corpus/Xvfb/audit-seed10/meta.toml new file mode 100644 index 00000000..3ffd978c --- /dev/null +++ b/corpus/Xvfb/audit-seed10/meta.toml @@ -0,0 +1,45 @@ +[bless] +provenance = "agent" + +[tool] +name = "Xvfb" +version = "audit-seed10" +platform = "ubuntu-24.04" +captured_with = "manual capture per corpus/README.md step 2 (TERM=dumb NO_COLOR=1 COLUMNS=100 LC_ALL=C.UTF-8); xvfb 2:21.1.12-1ubuntu1.6" + +# Xvfb rejects --help and writes its whole response to stderr; stdout is +# empty. `help.txt` is committed empty, the shape `corpus/jinfo/17.0.20` +# uses, since `[[capture]].stdout` is a required field. +[[capture]] +argv = ["Xvfb", "--help"] +stdout = "help.txt" +stderr = "help.stderr.txt" +exit_code = 1 + +[contract] +expected_framework = "generic" +must_contain_flags = ["-audit", "-auth", "-fp", "-help"] + +# `[+-]accessx`'s own description must never name a flag group. It does +# today, which is what keeps this fixture `[xfail]`; S-163 and S-165 on the +# document-shape branch are the fix. +must_not_contain_flag_group_prefixes = ["enable/disable accessx"] + +# Bare-word single-dash-long-table values (docs/shapes.md S-157): each +# used to read as a boolean, its value name silently dropped, absorbed +# into the row's own description column. +[contract.must_value_name] +"-audit" = "int" +"-auth" = "file" +"-fp" = "string" + +[xfail] +broken = true +reason = """ +S-157 recovers the bare-word value names this contract asserts (`-audit int`, +`-auth file`, `-fp string`), and the tree is still wrong in two ways this rule +does not reach. `[+-]accessx`'s own description becomes a fabricated flag group, +and the `+word` rows reach nothing. Both need S-163 and S-165, which live on the +document-shape branch. The contract fields above already state what must hold +once all three land. +""" diff --git a/corpus/cargo-clippy/0.1.97/help.txt b/corpus/cargo-clippy/0.1.97/help.txt new file mode 100644 index 00000000..2c35777d --- /dev/null +++ b/corpus/cargo-clippy/0.1.97/help.txt @@ -0,0 +1,33 @@ +Checks a package to catch common mistakes and improve your Rust code. + +Usage: + cargo clippy [OPTIONS] [--] [...] + +Common options: + --no-deps Run Clippy only on the given crate, without linting the dependencies + --fix Automatically apply lint suggestions. This flag implies --no-deps and --all-targets + -h, --help Print this message + -V, --version Print version info and exit + --explain [LINT] Print the documentation for a given lint + +See all options with cargo check --help. + +Allowing / Denying lints + +To allow or deny a lint from the command line you can use cargo clippy -- with: + + -W / --warn [LINT] Set lint warnings + -A / --allow [LINT] Set lint allowed + -D / --deny [LINT] Set lint denied + -F / --forbid [LINT] Set lint forbidden + +You can use tool lints to allow or deny lints from your code, e.g.: + + #[allow(clippy::needless_lifetimes)] + +Manifest Options: + --manifest-path Path to Cargo.toml + --frozen Require Cargo.lock and cache are up to date + --locked Require Cargo.lock is up to date + --offline Run without accessing the network + diff --git a/corpus/cargo-clippy/0.1.97/meta.toml b/corpus/cargo-clippy/0.1.97/meta.toml new file mode 100644 index 00000000..221762bf --- /dev/null +++ b/corpus/cargo-clippy/0.1.97/meta.toml @@ -0,0 +1,44 @@ +# docs/shapes.md S-161. Seed 7, maintainer item 1: "-W took / as a +# placeholder and did not pair with its long form." +# +# The four rows of the "Allowing / Denying lints" block join their two +# spellings with a spaced slash — `-W / --warn [LINT]` — so `-W` takes the +# literal `/` as its value name and `--warn`, `--allow`, `--deny` and +# `--forbid` reach the tree nowhere at all. Round 10 lifted the `/`-joining +# repair out of S-144's lowdown-bullet gate and into the ordinary +# option-table emit path, which is a real widening with zero fleet losses, +# and it does NOT reach these rows: this document's rows are read by a +# different row reader, so the tree is unchanged here and +# `slash-joined-alias-outside-bullet` still reads 1 tool / 4 findings +# fleet-wide. This fixture states that, so the gap is a failing contract +# rather than a silence. + +[bless] +provenance = "agent" + +[tool] +name = "cargo-clippy" +version = "0.1.97" +platform = "ubuntu-24.04 (aarch64)" +captured_with = "manual capture per corpus/README.md step 2 (TERM=dumb NO_COLOR=1 COLUMNS=100 LC_ALL=C.UTF-8); clippy 0.1.97 (8bab26f4f6 2026-07-14)" + +[[capture]] +argv = ["cargo-clippy", "--help"] +stdout = "help.txt" +exit_code = 0 + +[contract] +must_contain_flags = ["--warn", "--allow", "--deny", "--forbid"] + +[contract.must_not_value_name] +"-W" = "/" +"-A" = "/" +"-D" = "/" +"-F" = "/" + +[contract.must_describe] +"-W" = "Set lint warnings" + +[xfail] +broken = true +reason = "[S-161] the rows `-W / --warn [LINT]` join their two spellings with a spaced slash, so -W takes / as its value name and --warn reaches nothing; the same for -A/--allow, -D/--deny and -F/--forbid. The join repair shipped this round covers the ordinary option-table emit path and does not reach this document's row reader. slash-joined-alias-outside-bullet reads 1 tool / 4 findings fleet-wide, below the five-tool bar; nothing ships for it." diff --git a/corpus/dpkg-statoverride/audit-seed2/expected.snap b/corpus/dpkg-statoverride/audit-seed2/expected.snap index d3a7eb8e..4fbdbec4 100644 --- a/corpus/dpkg-statoverride/audit-seed2/expected.snap +++ b/corpus/dpkg-statoverride/audit-seed2/expected.snap @@ -73,7 +73,7 @@ flags: - help-text - spellings: - --force- - value_name: + value_name: [,...] value_kind: Required description: override problems (see --force-help). provenance: @@ -81,7 +81,7 @@ flags: - help-text - spellings: - --no-force- - value_name: + value_name: [,...] value_kind: Required description: stop when problems encountered. provenance: @@ -89,7 +89,7 @@ flags: - help-text - spellings: - --refuse- - value_name: + value_name: [,...] value_kind: Required description: ditto. provenance: diff --git a/corpus/dpkg/1.22.6/expected.snap b/corpus/dpkg/1.22.6/expected.snap index 4f235fb7..48bff2fc 100644 --- a/corpus/dpkg/1.22.6/expected.snap +++ b/corpus/dpkg/1.22.6/expected.snap @@ -459,7 +459,7 @@ flags: - help-text - spellings: - --force- - value_name: + value_name: [,...] value_kind: Required description: Override problems (see --force-help). provenance: @@ -467,7 +467,7 @@ flags: - help-text - spellings: - --no-force- - value_name: + value_name: [,...] value_kind: Required description: Stop when problems encountered. provenance: @@ -475,7 +475,7 @@ flags: - help-text - spellings: - --refuse- - value_name: + value_name: [,...] value_kind: Required description: Ditto. provenance: diff --git a/corpus/grub-mkimage/2.12/help.txt b/corpus/grub-mkimage/2.12/help.txt new file mode 100644 index 00000000..c7e1778d --- /dev/null +++ b/corpus/grub-mkimage/2.12/help.txt @@ -0,0 +1,44 @@ +Usage: grub-mkimage [OPTION...] [OPTION]... [MODULES] +Make a bootable image of GRUB. + + -c, --config=FILE embed FILE as an early config + -C, --compression=(xz|none|auto) + choose the compression to use for core image + --disable-shim-lock disable shim_lock verifier + -d, --directory=DIR use images and modules under DIR + [default=/usr/lib/grub/] + -D, --dtb=FILE embed FILE as a device tree (DTB) + + -k, --pubkey=FILE embed FILE as public key for signature checking + -m, --memdisk=FILE embed FILE as a memdisk image +Implies `-p (memdisk)/boot/grub' and overrides + any prefix supplied previously, but the prefix + itself can be overridden by later options + -n, --note add NOTE segment for CHRP IEEE1275 + -o, --output=FILE output a generated image to FILE [default=stdout] + -O, --format=FORMAT generate an image in FORMAT + available formats: i386-coreboot, i386-multiboot, + i386-pc, i386-xen_pvh, i386-pc-pxe, + i386-pc-eltorito, i386-efi, i386-ieee1275, + i386-qemu, x86_64-efi, i386-xen, x86_64-xen, + mipsel-yeeloong-flash, mipsel-fuloong2f-flash, + mipsel-loongson-elf, powerpc-ieee1275, + sparc64-ieee1275-raw, sparc64-ieee1275-cdcore, + sparc64-ieee1275-aout, ia64-efi, mips-arc, + mipsel-arc, mipsel-qemu_mips-elf, + mips-qemu_mips-flash, mipsel-qemu_mips-flash, + mips-qemu_mips-elf, arm-uboot, + arm-coreboot-vexpress, arm-coreboot-veyron, + arm-efi, arm64-efi, loongarch64-efi, riscv32-efi, + riscv64-efi + -p, --prefix=DIR set prefix directory + -s, --sbat=FILE SBAT metadata + -v, --verbose print verbose messages. + -?, --help give this help list + --usage give a short usage message + -V, --version print program version + +Mandatory or optional arguments to long options are also mandatory or optional +for any corresponding short options. + +Report bugs to . diff --git a/corpus/grub-mkimage/2.12/meta.toml b/corpus/grub-mkimage/2.12/meta.toml new file mode 100644 index 00000000..a1e87b80 --- /dev/null +++ b/corpus/grub-mkimage/2.12/meta.toml @@ -0,0 +1,36 @@ +# [S-155] `-C, --compression=(xz|none|auto)` is one paren-delimited +# alternation of literal values in the value position. It rendered as an +# opaque placeholder holding the whole list; the fix reads it as +# `--compression`'s own `choices` instead. See docs/shapes.md S-155. + +[bless] +provenance = "agent" + +[tool] +name = "grub-mkimage" +version = "2.12" # grub-mkimage (GRUB) 2.12-1ubuntu7.3 +platform = "ubuntu-24.04" +captured_with = "manual capture per corpus/README.md step 2 (TERM=dumb NO_COLOR=1 COLUMNS=100 LC_ALL=C.UTF-8); grub2-common 2.12-1ubuntu7.3" + +[[capture]] +argv = ["grub-mkimage", "--help"] +stdout = "help.txt" + +[contract] +expected_framework = "GNU argp/getopt_long" +min_status = "ok" + +[contract.must_attach_choices] +"--compression" = ["xz", "none", "auto"] +# [S-156] Open: still fails today. --format's own choices live only in its +# description's "available formats:" tail, never attached as a real +# choices list. This assertion is the fixture's own evidence that S-156 +# stays [xfail] below. +"--format" = ["i386-coreboot", "i386-multiboot", "i386-pc", "i386-xen_pvh", "i386-pc-pxe", "i386-pc-eltorito", "i386-efi", "i386-ieee1275", "i386-qemu", "x86_64-efi", "i386-xen", "x86_64-xen", "mipsel-yeeloong-flash", "mipsel-fuloong2f-flash", "mipsel-loongson-elf", "powerpc-ieee1275", "sparc64-ieee1275-raw", "sparc64-ieee1275-cdcore", "sparc64-ieee1275-aout", "ia64-efi", "mips-arc", "mipsel-arc", "mipsel-qemu_mips-elf", "mips-qemu_mips-flash", "mipsel-qemu_mips-flash", "mips-qemu_mips-elf", "arm-uboot", "arm-coreboot-vexpress", "arm-coreboot-veyron", "arm-efi", "arm64-efi", "loongarch64-efi", "riscv32-efi", "riscv64-efi"] + +[contract.must_not_value_name] +"--compression" = "xz|none|auto" + +[xfail] +broken = true +reason = "S-155 is fixed: --compression's paren-delimited alternation attaches as choices, asserted above. S-156 is open: --format's description continuation opens 'available formats:' and runs 33 comma-separated literal values to the end, never becoming --format's own choices; description-tail-enumerates-choices measures 1 genuine tool fleet-wide (a 36-tool sample built from a grep over audit/queue-captures for the four labels, plus rustc and tclobjnew-bpfcc), below the five-tool bar, so nothing ships for it this round." diff --git a/corpus/javaflow-bpfcc/audit-seed2/expected.snap b/corpus/javaflow-bpfcc/audit-seed2/expected.snap index b320691f..a3a64da8 100644 --- a/corpus/javaflow-bpfcc/audit-seed2/expected.snap +++ b/corpus/javaflow-bpfcc/audit-seed2/expected.snap @@ -19,8 +19,14 @@ flags: - spellings: - -l - --language - value_name: '{java,perl,php,python,ruby,tcl}' value_kind: Required + choices: + - java + - perl + - php + - python + - ruby + - tcl description: language to trace provenance: sources: diff --git a/corpus/lto-dump/13.3.0/expected.snap b/corpus/lto-dump/13.3.0/expected.snap index 881a4361..54ae090b 100644 --- a/corpus/lto-dump/13.3.0/expected.snap +++ b/corpus/lto-dump/13.3.0/expected.snap @@ -2478,7 +2478,7 @@ flags: - help-text - spellings: - -D - value_name: + value_name: [=] value_kind: Required group: 'The following options are language-related:' provenance: diff --git a/corpus/mksquashfs/4.6.1/expected.snap b/corpus/mksquashfs/4.6.1/expected.snap index 1c355aaf..0cdbff13 100644 --- a/corpus/mksquashfs/4.6.1/expected.snap +++ b/corpus/mksquashfs/4.6.1/expected.snap @@ -758,6 +758,8 @@ flags: - help-text - spellings: - -Xstrategy + value_name: strategy1,strategy2,...,strategyN + value_kind: Required group: gzip (default) description: 'Compress using strategy1,strategy2,...,strategyN in turn and choose the best compression. Available strategies: default, filtered, huffman_only, run_length_encoded and fixed' provenance: @@ -790,6 +792,8 @@ flags: - help-text - spellings: - -Xbcj + value_name: filter1,filter2,...,filterN + value_kind: Required group: xz description: 'Compress using filter1,filter2,...,filterN in turn (in addition to no filter), and choose the best compression. Available filters: x86, arm, armthumb, powerpc, sparc, ia64' provenance: diff --git a/corpus/mksquashfs/4.6.1/meta.toml b/corpus/mksquashfs/4.6.1/meta.toml index 780d2072..3885f26d 100644 --- a/corpus/mksquashfs/4.6.1/meta.toml +++ b/corpus/mksquashfs/4.6.1/meta.toml @@ -46,6 +46,10 @@ must_usage_forms_min = 1 "-mem" = "" "-comp" = "" "-mkfs-time" = "