[Python-checkins] CVS: python/nondist/peps pep-0271.txt,NONE,1.1

Barry Warsaw bwarsaw@users.sourceforge.net
Thu, 13 Sep 2001 09:46:46 -0700


Update of /cvsroot/python/python/nondist/peps
In directory usw-pr-cvs1:/tmp/cvs-serv9015

Added Files:
	pep-0271.txt 
Log Message:
PEP 271, Prefixing sys.path by command line option, Giacometti

(formatting by BAW)


--- NEW FILE: pep-0271.txt ---
PEP: 271
Title: Prefixing sys.path by command line option
Version: $Revision: 1.1 $
Last-Modified: $Date: 2001/09/13 16:46:44 $
Author: fred@arakne.com (Frédéric B. Giacometti) 
Status: Draft
Type: Standards Track
Created: 15-Aug-2001
Python-Version: 2.2
Post-History:


Abstract

    At present, setting the PYTHONPATH environment variable is the
    only method for defining additional Python module search
    directories.

    This PEP introduces the '-P' valued option to the python command
    as an alternative to PYTHONPATH.


Rationale

    On Unix:

        python -P $SOMEVALUE

    will be equivalent to

        env PYTHONPATH=$SOMEVALUE python

    On Windows 2K:

        python -P %SOMEVALUE%

    will (almost) be equivalent to

        set __PYTHONPATH=%PYTHONPATH% && set PYTHONPATH=%SOMEVALUE%\
            && python && set PYTHONPATH=%__PYTHONPATH%
        

Other Information

    This option is equivalent to the 'java -classpath' option.


When to use this option

    This option is intended to ease and make more robust the use of
    Python in test or build scripts, for instance.


Reference Implementation

    See patch.
  

Copyright

    This document has been placed in the public domain.



Local Variables:
mode: indented-text
indent-tabs-mode: nil
fill-column: 70
End: