Use JSON output for getting product versions
radeksimko opened this issue · comments
Radek Simko commented
Currently we leverage the default (mainly human-readable) output of terraform version
and consul version
, but both have introduced JSON output which we could leverage and fall back to the default human output if parsing or execution fails.
https://www.terraform.io/docs/cli/commands/version.html#json
https://www.consul.io/commands/version#json-output
hc-install/product/terraform.go
Lines 29 to 49 in 9fcc92b
Lines 31 to 51 in 9fcc92b