maths in grc formulas
withnale opened this issue · 1 comments
withnale commented
Is there any way to write a formula that can make use of arithmetic functions, or is there a clean way of implementing this a new feature?
One example case springs to mind using grc with kubectl
NAME READY UP-TO-DATE AVAILABLE AGE
api1 1/1 1 1 33d
ui 1/1 1 1 33d
api2 2/2 2 1 33d
auth 3/4 1 1 33d
client 0/1 1 1 33d
event 1/1 1 1 33d
postgres 2/2 2 2 33d
In the above example:
- both client and auth are in error because their
READY
column has is 0/1 and 3/4 - api2 is also in error because only 1 of the 2 instances are up-to-date
lnxbil commented
grc
is able to forward the found text to a program, maybe, you can fiddle around with this.