aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/dist.py
diff options
context:
space:
mode:
authorSachi King <nakato@nakato.io>2015-12-07 19:52:21 +1300
committerSachi King <nakato@nakato.io>2015-12-07 19:52:21 +1300
commitfc916c8ea1f7ac0ee5cc56dfaa0ab4ef6aee1cfb (patch)
tree3134f5e685876c26f04fd1afabbf5d7637b62f8b /setuptools/dist.py
parentb859bf9ded7c6d4fb056a0b47a11caea6321de60 (diff)
downloadexternal_python_setuptools-fc916c8ea1f7ac0ee5cc56dfaa0ab4ef6aee1cfb.tar.gz
external_python_setuptools-fc916c8ea1f7ac0ee5cc56dfaa0ab4ef6aee1cfb.tar.bz2
external_python_setuptools-fc916c8ea1f7ac0ee5cc56dfaa0ab4ef6aee1cfb.zip
Add get_command_list to dist and process distutils.commands entry points
--HG-- branch : get_command_list
Diffstat (limited to 'setuptools/dist.py')
-rw-r--r--setuptools/dist.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/setuptools/dist.py b/setuptools/dist.py
index d7ad4655..c5f04b33 100644
--- a/setuptools/dist.py
+++ b/setuptools/dist.py
@@ -440,6 +440,14 @@ class Distribution(_Distribution):
self.cmdclass[ep.name] = cmdclass
return _Distribution.print_commands(self)
+ def get_command_list(self):
+ for ep in pkg_resources.iter_entry_points('distutils.commands'):
+ if ep.name not in self.cmdclass:
+ # don't require extras as the commands won't be invoked
+ cmdclass = ep.resolve()
+ self.cmdclass[ep.name] = cmdclass
+ return _Distribution.get_command_list(self)
+
def _set_feature(self,name,status):
"""Set feature's inclusion status"""
setattr(self,self._feature_attrname(name),status)