A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2007-April/072430.html below:

[Python-Dev] proposed which.py replacement

[Python-Dev] proposed which.py replacement [Python-Dev] proposed which.py replacementStefan Rank list-ener at strank.info
Sun Apr 1 18:41:54 CEST 2007
on 01.04.2007 17:23 Guido van Rossum said the following:
> It's out of character for the standard library, since (regardless of
> whether it's implemented in Python or part of the standard library)
> it's a stand-alone utility. I don't see much use for this as a library
> module.

I use it as a library, because it encodes knowledge about locating 
executables on different platforms, especially Windows.
Unixoids have which and the search is relatively straightforward.
Windows searches paths in PATH and in the registry, and uses PATHEXT,
so, for me, the main benefit of which.py is that it provides a which 
replacement on Windows that takes these quirks into account.

A small use case, but a use case nevertheless.

I never use which.py as a stand-alone utility as I have cygwin.
(But I think it would be helpful when deploying on somebody else's 
Windows computer.)

Of course it is your call if it fits in the stdlib or not.

cheers,
stefan

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4