From e2e15d52473c52071d331b415bcf949f8e848a22 Mon Sep 17 00:00:00 2001 From: xoviat Date: Sun, 15 Oct 2017 12:53:22 -0500 Subject: dist_info: create the egg_info in the same location This change is a small simplification that simply creates the egg_info directory in the egg_base location; it's a minor cleanup that results in some read and it helps with read-only directories (the egg_info directory is uncontrollable). --- setuptools/command/dist_info.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'setuptools/command') diff --git a/setuptools/command/dist_info.py b/setuptools/command/dist_info.py index c6c6dacb..28b88c88 100644 --- a/setuptools/command/dist_info.py +++ b/setuptools/command/dist_info.py @@ -4,7 +4,6 @@ As defined in the wheel specification """ import os -import shutil from distutils.core import Command from distutils import log @@ -27,14 +26,10 @@ class dist_info(Command): def run(self): egg_info = self.get_finalized_command('egg_info') + egg_info.egg_base = self.egg_base egg_info.run() dist_info_dir = egg_info.egg_info[:-len('.egg-info')] + '.dist-info' log.info("creating '{}'".format(os.path.abspath(dist_info_dir))) bdist_wheel = self.get_finalized_command('bdist_wheel') bdist_wheel.egg2dist(egg_info.egg_info, dist_info_dir) - - if self.egg_base: - destination = os.path.join(self.egg_base, dist_info_dir) - log.info("creating '{}'".format(os.path.abspath(destination))) - shutil.move(dist_info_dir, destination) -- cgit v1.2.1