h4l / json.bash

Command-line tool and bash library that creates JSON
MIT License
436 stars 8 forks source link

Improve JSON validator co-process error handling #15

Closed h4l closed 2 months ago

h4l commented 2 months ago

This PR hardens the interaction with the JSON validator co-process, to avoid the error seen in #10 with _PID not being set after starting a coproc.

Related to this, we also now support using the JSON_BASH_GREP envar to change the grep command to a custom path, and we default to ggrep if it's available.

This resolves #12.