Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/cmdclass.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,9 @@ def run(self):
# then does setup.py bdist_wheel, or sometimes setup.py install
# setup.py egg_info -> ?

# pip install -e . and setuptool/editable_wheel will invoke build_py
# but the build_py command is not expected to copy any files.

# we override different "build_py" commands for both environments
if 'build_py' in cmds:
_build_py = cmds['build_py']
Expand All @@ -81,6 +84,10 @@ def run(self):
cfg = get_config_from_root(root)
versions = get_versions()
_build_py.run(self)
if getattr(self, "editable_mode", False):
# During editable installs `.py` and data files are
# not copied to build_lib
return
# now locate _version.py in the new build/ directory and replace
# it with an updated value
if cfg.versionfile_build:
Expand Down