Closed egibs closed 3 days ago
Can we simplify the exit messages? Instead of:
π no matching capabilities in "/Library/Application Support/BTServer/pincode_defaults.db" kind=file suffix=: matched requested condition π 1 matching capabilities in /usr/bin/SafeEjectGPU file: net/url/parse: matched requested condition
How about something closer to:
π /Library/Application Support/BTServer/pincode_defaults.db matched exit criteria π /usr/bin/SafeEjectGPU matched exit criteria
In the second case, in particular, we can already see the list of capabilities just above this line. Eventually we should rename these flags to --exit-if
instead of --err-if
- that can be done here or in another PR.
Can we simplify the exit messages? Instead of:
π no matching capabilities in "/Library/Application Support/BTServer/pincode_defaults.db" kind=file suffix=: matched requested condition π 1 matching capabilities in /usr/bin/SafeEjectGPU file: net/url/parse: matched requested condition
How about something closer to:
π /Library/Application Support/BTServer/pincode_defaults.db matched exit criteria π /usr/bin/SafeEjectGPU matched exit criteria
In the second case, in particular, we can already see the list of capabilities just above this line. Eventually we should rename these flags to
--exit-if
instead of--err-if
- that can be done here or in another PR.
Updated in c949cc4
(#624).
Renamed the errIfHitOrMiss
function in 2f68252
(#624) as well.
Closes: #623
This PR allows for hits and misses surfaced by
--err-first-hit
or--err-first-miss
to be displayed while also preventing additional concurrent processing/rendering of other paths.This is achieved with a separate goroutine that reads from a channel that stores only the first match returned by
errIfHitOrMiss
and propagates the match and error properly.Example output: