gregfelice commented on PR #2445:
URL: https://github.com/apache/age/pull/2445#issuecomment-4811275063
Thanks @jrgemignani — addressed the Copilot note in 71fe83e0.
The version guard now parses the field with `awk 'NR==1 {print $NF}'`
instead of the `grep -oE` regex, and errors explicitly when the version can't
be determined (instead of falling through to the confusing `Bison != 3.8.x`
message):
```sh
ver=$(bison --version | awk 'NR==1 {print $NF}')
if [ -z "$ver" ]; then
echo "::error::Could not determine Bison version from 'bison --version'."
exit 1
fi
```
Verified the parse against `bison (GNU Bison) 3.8.2` → `3.8.2` and empty
input → caught by the guard.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]