]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Closes #15173: Tidied up copyright statements and removed pythonv references.
authorVinay Sajip <vinay_sajip@yahoo.co.uk>
Sun, 24 Jun 2012 23:47:46 +0000 (00:47 +0100)
committerVinay Sajip <vinay_sajip@yahoo.co.uk>
Sun, 24 Jun 2012 23:47:46 +0000 (00:47 +0100)
Lib/site.py
Lib/test/test_venv.py
Lib/venv/__init__.py
Mac/Tools/pythonw.c

index a298f26a69029615e1ed24b041e33f4f4825df8f..a0f98b361b14993f1b7ee83bd9d213416976a135 100644 (file)
@@ -499,8 +499,8 @@ def venv(known_paths):
     global PREFIXES, ENABLE_USER_SITE
 
     env = os.environ
-    if sys.platform == 'darwin' and '__PYTHONV_LAUNCHER__' in env:
-        executable = os.environ['__PYTHONV_LAUNCHER__']
+    if sys.platform == 'darwin' and '__PYVENV_LAUNCHER__' in env:
+        executable = os.environ['__PYVENV_LAUNCHER__']
     else:
         executable = sys.executable
     executable_dir, executable_name = os.path.split(executable)
index 45a29873f8776b5650c9fdd1e5051eda000b2ead..705fd39471802ecf8a71b6b3f858ca8049d9e8f2 100644 (file)
@@ -2,6 +2,7 @@
 Test harness for the venv module.
 
 Copyright (C) 2011-2012 Vinay Sajip.
+Licensed to the PSF under a contributor agreement.
 """
 
 import os
@@ -29,8 +30,8 @@ class BaseTest(unittest.TestCase):
             self.pydocname = 'pydoc'
             self.lib = ('lib', 'python%s' % sys.version[:3])
             self.include = 'include'
-        if sys.platform == 'darwin' and '__PYTHONV_LAUNCHER__' in os.environ:
-            executable = os.environ['__PYTHONV_LAUNCHER__']
+        if sys.platform == 'darwin' and '__PYVENV_LAUNCHER__' in os.environ:
+            executable = os.environ['__PYVENV_LAUNCHER__']
         else:
             executable = sys.executable
         self.exe = os.path.split(executable)[-1]
@@ -69,9 +70,9 @@ class BasicTest(BaseTest):
         self.isdir(self.include)
         self.isdir(*self.lib)
         data = self.get_text_file_contents('pyvenv.cfg')
-        if sys.platform == 'darwin' and ('__PYTHONV_LAUNCHER__'
+        if sys.platform == 'darwin' and ('__PYVENV_LAUNCHER__'
                                          in os.environ):
-            executable =  os.environ['__PYTHONV_LAUNCHER__']
+            executable =  os.environ['__PYVENV_LAUNCHER__']
         else:
             executable = sys.executable
         path = os.path.dirname(executable)
@@ -127,7 +128,7 @@ class BasicTest(BaseTest):
         for usl in (False, True):
             builder = venv.EnvBuilder(clear=True, symlinks=usl)
             if (usl and sys.platform == 'darwin' and
-                '__PYTHONV_LAUNCHER__' in os.environ):
+                '__PYVENV_LAUNCHER__' in os.environ):
                 self.assertRaises(ValueError, builder.create, self.env_dir)
             else:
                 builder.create(self.env_dir)
index 0371cafca8bf0dc9b43ad4d948191db7290c4edb..3d9d3b7e5684371c3485dfd7ec53d9b0304f1df0 100644 (file)
@@ -1,7 +1,8 @@
 """
 Virtual environment (venv) package for Python. Based on PEP 405.
 
-Copyright (C) 20011-2012 Vinay Sajip. All Rights Reserved.
+Copyright (C) 2011-2012 Vinay Sajip.
+Licensed to the PSF under a contributor agreement.
 
 usage: python -m venv [-h] [--system-site-packages] [--symlinks] [--clear]
             [--upgrade]
@@ -36,7 +37,6 @@ try:
     import threading
 except ImportError:
     threading = None
-import zipfile
 
 logger = logging.getLogger(__name__)
 
@@ -119,8 +119,8 @@ class EnvBuilder:
         context.prompt = '(%s) ' % context.env_name
         create_if_needed(env_dir)
         env = os.environ
-        if sys.platform == 'darwin' and '__PYTHONV_LAUNCHER__' in env:
-            executable = os.environ['__PYTHONV_LAUNCHER__']
+        if sys.platform == 'darwin' and '__PYVENV_LAUNCHER__' in env:
+            executable = os.environ['__PYVENV_LAUNCHER__']
         else:
             executable = sys.executable
         dirname, exename = os.path.split(os.path.abspath(executable))
@@ -346,8 +346,7 @@ def main(args=None):
     elif not hasattr(sys, 'base_prefix'):
         compatible = False
     if not compatible:
-        raise ValueError('This script is only for use with '
-                         'Python 3.3 (pythonv variant)')
+        raise ValueError('This script is only for use with Python 3.3')
     else:
         import argparse
 
index ebee5312f89fc5f8e35db945c5f4a1e03b7fd59f..f5cdff52d028ace8e94b2ae8496f4713d6c4eaa5 100644 (file)
@@ -159,7 +159,7 @@ main(int argc, char **argv) {
     status = _NSGetExecutablePath(path, &size);
     if (status == 0) {
         if (realpath(path, real_path) != NULL) {
-            setenv("__PYTHONV_LAUNCHER__", real_path, 1);
+            setenv("__PYVENV_LAUNCHER__", real_path, 1);
         }
     }