Cache exe lookups

This commit is contained in:
Kovid Goyal 2021-02-04 11:36:59 +05:30
parent 7eba3b6cbc
commit af94e07618
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C

View file

@ -538,6 +538,7 @@ def add_from_file(x: str) -> None:
return entries
@lru_cache
def find_exe(name: str) -> Optional[str]:
import shutil
ans = shutil.which(name)