def which(*programs, **shutilwhich_kwargs): from rez.backport.shutilwhich import which as which_ for prog in programs: path = which_(prog, **shutilwhich_kwargs) if path: return path return None