Brian Curtin <cur...@acm.org> added the comment: Here is a patch against r76432 which implements a "which" generator function in shutil that yields full file paths where the searched file exists on the PATH. Includes doc change and a test. It is pretty similar to what edemaine had suggested.
This could just as easily return a list, so if that would be more preferable I'll change the patch. ---------- nosy: +brian.curtin Added file: http://bugs.python.org/file15381/shutil_which.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue444582> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com