def install_pip(env, requirements): """Install pip and its requirements using setuptools.""" try: installation_source_folder = config.installation_cache_folder() options = setuptools_install_options(installation_source_folder) if installation_source_folder is not None: zip_eggs_in_folder(installation_source_folder) env.execute(["-m", "easy_install"] + options + requirements) except (KeyboardInterrupt, SystemExit): raise except Exception: raise EnvironmentSetupError("pip installation failed.")
def download_pip(env, requirements): """Download pip and its requirements using setuptools.""" if config.installation_cache_folder() is None: raise EnvironmentSetupError("Local installation cache folder not " "defined but required for downloading a pip installation.") # Installation cache folder needs to be explicitly created for setuptools # to be able to copy its downloaded installation files into it. Seen using # Python 2.4.4 & setuptools 1.4. _create_installation_cache_folder_if_needed() try: env.execute(["-m", "easy_install", "--zip-ok", "--multi-version", "--always-copy", "--exclude-scripts", "--install-dir", config.installation_cache_folder()] + requirements) zip_eggs_in_folder(config.installation_cache_folder()) except (KeyboardInterrupt, SystemExit): raise except Exception: raise EnvironmentSetupError("pip download failed.")
def download_pip(env, requirements): """Download pip and its requirements using setuptools.""" if config.installation_cache_folder() is None: raise EnvironmentSetupError( "Local installation cache folder not " "defined but required for downloading a pip installation.") # Installation cache folder needs to be explicitly created for setuptools # to be able to copy its downloaded installation files into it. Seen using # Python 2.4.4 & setuptools 1.4. _create_installation_cache_folder_if_needed() try: env.execute([ "-m", "easy_install", "--zip-ok", "--multi-version", "--always-copy", "--exclude-scripts", "--install-dir", config.installation_cache_folder() ] + requirements) zip_eggs_in_folder(config.installation_cache_folder()) except (KeyboardInterrupt, SystemExit): raise except Exception: raise EnvironmentSetupError("pip download failed.")