def env_first
import cli@0.2.0.0/cli.bend as Cliimport Base
3734# found, or else the first of names that is set and not empty in vars.
3735def env_first(names: List<&2, String>, found: Maybe<&2, EnvValue>,
3736 +vars: List<&2, Var>) -> Maybe<&2, EnvValue>:
3737 match names:
3738 case Nil{}: found
3739 case name <> tail: env_first(tail, env_next(found, name, vars), vars)