diff options
author | David Douard <david.douard@logilab.fr> | 2015-03-13 15:18:12 +0100 |
---|---|---|
committer | David Douard <david.douard@logilab.fr> | 2015-03-13 15:18:12 +0100 |
commit | 84ba0c13c480f1e0fb3853caa6bc8ee48dd13178 (patch) | |
tree | 61ef71cc521fdba98a5b496029caa009e346ec88 | |
parent | b95ae183478e43f8a2229d6cbdfe79e389c0f6e3 (diff) | |
download | logilab-common-84ba0c13c480f1e0fb3853caa6bc8ee48dd13178.tar.gz |
[layout] change the source directory layout
The logilab.common package now lives in a logilab/common directory to make it pip compliant.
Related to #294479.
-rw-r--r-- | logilab/__init__.py | 1 | ||||
-rw-r--r-- | logilab/common/__init__.py (renamed from __init__.py) | 2 | ||||
-rw-r--r-- | logilab/common/__pkginfo__.py (renamed from __pkginfo__.py) | 0 | ||||
-rw-r--r-- | logilab/common/cache.py (renamed from cache.py) | 0 | ||||
-rw-r--r-- | logilab/common/changelog.py (renamed from changelog.py) | 0 | ||||
-rw-r--r-- | logilab/common/clcommands.py (renamed from clcommands.py) | 0 | ||||
-rw-r--r-- | logilab/common/cli.py (renamed from cli.py) | 0 | ||||
-rw-r--r-- | logilab/common/compat.py (renamed from compat.py) | 0 | ||||
-rw-r--r-- | logilab/common/configuration.py (renamed from configuration.py) | 0 | ||||
-rw-r--r-- | logilab/common/contexts.py (renamed from contexts.py) | 0 | ||||
-rw-r--r-- | logilab/common/corbautils.py (renamed from corbautils.py) | 0 | ||||
-rw-r--r-- | logilab/common/daemon.py (renamed from daemon.py) | 0 | ||||
-rw-r--r-- | logilab/common/date.py (renamed from date.py) | 0 | ||||
-rw-r--r-- | logilab/common/dbf.py (renamed from dbf.py) | 0 | ||||
-rw-r--r-- | logilab/common/debugger.py (renamed from debugger.py) | 0 | ||||
-rw-r--r-- | logilab/common/decorators.py (renamed from decorators.py) | 0 | ||||
-rw-r--r-- | logilab/common/deprecation.py (renamed from deprecation.py) | 0 | ||||
-rw-r--r-- | logilab/common/fileutils.py (renamed from fileutils.py) | 0 | ||||
-rw-r--r-- | logilab/common/graph.py (renamed from graph.py) | 0 | ||||
-rw-r--r-- | logilab/common/interface.py (renamed from interface.py) | 0 | ||||
-rw-r--r-- | logilab/common/logging_ext.py (renamed from logging_ext.py) | 0 | ||||
-rw-r--r-- | logilab/common/modutils.py (renamed from modutils.py) | 0 | ||||
-rw-r--r-- | logilab/common/optik_ext.py (renamed from optik_ext.py) | 0 | ||||
-rw-r--r-- | logilab/common/optparser.py (renamed from optparser.py) | 0 | ||||
-rw-r--r-- | logilab/common/proc.py (renamed from proc.py) | 0 | ||||
-rw-r--r-- | logilab/common/pyro_ext.py (renamed from pyro_ext.py) | 0 | ||||
-rw-r--r-- | logilab/common/pytest.py (renamed from pytest.py) | 0 | ||||
-rw-r--r-- | logilab/common/registry.py (renamed from registry.py) | 0 | ||||
-rw-r--r-- | logilab/common/shellutils.py (renamed from shellutils.py) | 0 | ||||
-rw-r--r-- | logilab/common/sphinx_ext.py (renamed from sphinx_ext.py) | 0 | ||||
-rw-r--r-- | logilab/common/sphinxutils.py (renamed from sphinxutils.py) | 0 | ||||
-rw-r--r-- | logilab/common/table.py (renamed from table.py) | 0 | ||||
-rw-r--r-- | logilab/common/tasksqueue.py (renamed from tasksqueue.py) | 0 | ||||
-rw-r--r-- | logilab/common/testlib.py (renamed from testlib.py) | 0 | ||||
-rw-r--r-- | logilab/common/textutils.py (renamed from textutils.py) | 0 | ||||
-rw-r--r-- | logilab/common/tree.py (renamed from tree.py) | 0 | ||||
-rw-r--r-- | logilab/common/umessage.py (renamed from umessage.py) | 0 | ||||
-rw-r--r-- | logilab/common/ureports/__init__.py (renamed from ureports/__init__.py) | 0 | ||||
-rw-r--r-- | logilab/common/ureports/docbook_writer.py (renamed from ureports/docbook_writer.py) | 0 | ||||
-rw-r--r-- | logilab/common/ureports/html_writer.py (renamed from ureports/html_writer.py) | 0 | ||||
-rw-r--r-- | logilab/common/ureports/nodes.py (renamed from ureports/nodes.py) | 0 | ||||
-rw-r--r-- | logilab/common/ureports/text_writer.py (renamed from ureports/text_writer.py) | 0 | ||||
-rw-r--r-- | logilab/common/urllib2ext.py (renamed from urllib2ext.py) | 0 | ||||
-rw-r--r-- | logilab/common/vcgutils.py (renamed from vcgutils.py) | 0 | ||||
-rw-r--r-- | logilab/common/visitor.py (renamed from visitor.py) | 0 | ||||
-rw-r--r-- | logilab/common/xmlrpcutils.py (renamed from xmlrpcutils.py) | 0 | ||||
-rw-r--r-- | logilab/common/xmlutils.py (renamed from xmlutils.py) | 0 | ||||
-rw-r--r-- | setup.py | 28 |
48 files changed, 16 insertions, 15 deletions
diff --git a/logilab/__init__.py b/logilab/__init__.py new file mode 100644 index 0000000..de40ea7 --- /dev/null +++ b/logilab/__init__.py @@ -0,0 +1 @@ +__import__('pkg_resources').declare_namespace(__name__) diff --git a/__init__.py b/logilab/common/__init__.py index 2d1324c..6a7c8b4 100644 --- a/__init__.py +++ b/logilab/common/__init__.py @@ -26,7 +26,6 @@ """ __docformat__ = "restructuredtext en" -from six.moves import range from logilab.common.__pkginfo__ import version as __version__ @@ -142,6 +141,7 @@ def make_domains(lists): >>> make_domains(['a', 'b'], ['c','d', 'e']) [['a', 'b', 'a', 'b', 'a', 'b'], ['c', 'c', 'd', 'd', 'e', 'e']] """ + from six.moves import range domains = [] for iterable in lists: new_domain = iterable[:] diff --git a/__pkginfo__.py b/logilab/common/__pkginfo__.py index 55a2cc3..55a2cc3 100644 --- a/__pkginfo__.py +++ b/logilab/common/__pkginfo__.py diff --git a/cache.py b/logilab/common/cache.py index 11ed137..11ed137 100644 --- a/cache.py +++ b/logilab/common/cache.py diff --git a/changelog.py b/logilab/common/changelog.py index 2fff2ed..2fff2ed 100644 --- a/changelog.py +++ b/logilab/common/changelog.py diff --git a/clcommands.py b/logilab/common/clcommands.py index 4778b99..4778b99 100644 --- a/clcommands.py +++ b/logilab/common/clcommands.py diff --git a/cli.py b/logilab/common/cli.py index cdeef97..cdeef97 100644 --- a/cli.py +++ b/logilab/common/cli.py diff --git a/compat.py b/logilab/common/compat.py index f2eb590..f2eb590 100644 --- a/compat.py +++ b/logilab/common/compat.py diff --git a/configuration.py b/logilab/common/configuration.py index b292427..b292427 100644 --- a/configuration.py +++ b/logilab/common/configuration.py diff --git a/contexts.py b/logilab/common/contexts.py index d78c327..d78c327 100644 --- a/contexts.py +++ b/logilab/common/contexts.py diff --git a/corbautils.py b/logilab/common/corbautils.py index 65c301d..65c301d 100644 --- a/corbautils.py +++ b/logilab/common/corbautils.py diff --git a/daemon.py b/logilab/common/daemon.py index 40319a4..40319a4 100644 --- a/daemon.py +++ b/logilab/common/daemon.py diff --git a/date.py b/logilab/common/date.py index a093a8a..a093a8a 100644 --- a/date.py +++ b/logilab/common/date.py diff --git a/dbf.py b/logilab/common/dbf.py index ab142b2..ab142b2 100644 --- a/dbf.py +++ b/logilab/common/dbf.py diff --git a/debugger.py b/logilab/common/debugger.py index 1f540a1..1f540a1 100644 --- a/debugger.py +++ b/logilab/common/debugger.py diff --git a/decorators.py b/logilab/common/decorators.py index beafa20..beafa20 100644 --- a/decorators.py +++ b/logilab/common/decorators.py diff --git a/deprecation.py b/logilab/common/deprecation.py index 1c81b63..1c81b63 100644 --- a/deprecation.py +++ b/logilab/common/deprecation.py diff --git a/fileutils.py b/logilab/common/fileutils.py index b30cf5f..b30cf5f 100644 --- a/fileutils.py +++ b/logilab/common/fileutils.py diff --git a/graph.py b/logilab/common/graph.py index cef1c98..cef1c98 100644 --- a/graph.py +++ b/logilab/common/graph.py diff --git a/interface.py b/logilab/common/interface.py index 3ea4ab7..3ea4ab7 100644 --- a/interface.py +++ b/logilab/common/interface.py diff --git a/logging_ext.py b/logilab/common/logging_ext.py index 3b6a580..3b6a580 100644 --- a/logging_ext.py +++ b/logilab/common/logging_ext.py diff --git a/modutils.py b/logilab/common/modutils.py index a426a3a..a426a3a 100644 --- a/modutils.py +++ b/logilab/common/modutils.py diff --git a/optik_ext.py b/logilab/common/optik_ext.py index 1fd2a7f..1fd2a7f 100644 --- a/optik_ext.py +++ b/logilab/common/optik_ext.py diff --git a/optparser.py b/logilab/common/optparser.py index aa17750..aa17750 100644 --- a/optparser.py +++ b/logilab/common/optparser.py diff --git a/proc.py b/logilab/common/proc.py index c27356c..c27356c 100644 --- a/proc.py +++ b/logilab/common/proc.py diff --git a/pyro_ext.py b/logilab/common/pyro_ext.py index 5204b1b..5204b1b 100644 --- a/pyro_ext.py +++ b/logilab/common/pyro_ext.py diff --git a/pytest.py b/logilab/common/pytest.py index 58515a9..58515a9 100644 --- a/pytest.py +++ b/logilab/common/pytest.py diff --git a/registry.py b/logilab/common/registry.py index a52b2eb..a52b2eb 100644 --- a/registry.py +++ b/logilab/common/registry.py diff --git a/shellutils.py b/logilab/common/shellutils.py index 4e68956..4e68956 100644 --- a/shellutils.py +++ b/logilab/common/shellutils.py diff --git a/sphinx_ext.py b/logilab/common/sphinx_ext.py index a24608c..a24608c 100644 --- a/sphinx_ext.py +++ b/logilab/common/sphinx_ext.py diff --git a/sphinxutils.py b/logilab/common/sphinxutils.py index ab6e8a1..ab6e8a1 100644 --- a/sphinxutils.py +++ b/logilab/common/sphinxutils.py diff --git a/table.py b/logilab/common/table.py index 2f3df69..2f3df69 100644 --- a/table.py +++ b/logilab/common/table.py diff --git a/tasksqueue.py b/logilab/common/tasksqueue.py index ed74cf5..ed74cf5 100644 --- a/tasksqueue.py +++ b/logilab/common/tasksqueue.py diff --git a/testlib.py b/logilab/common/testlib.py index 31efe56..31efe56 100644 --- a/testlib.py +++ b/logilab/common/testlib.py diff --git a/textutils.py b/logilab/common/textutils.py index 9046f97..9046f97 100644 --- a/textutils.py +++ b/logilab/common/textutils.py diff --git a/tree.py b/logilab/common/tree.py index 885eb0f..885eb0f 100644 --- a/tree.py +++ b/logilab/common/tree.py diff --git a/umessage.py b/logilab/common/umessage.py index a5e4799..a5e4799 100644 --- a/umessage.py +++ b/logilab/common/umessage.py diff --git a/ureports/__init__.py b/logilab/common/ureports/__init__.py index d76ebe5..d76ebe5 100644 --- a/ureports/__init__.py +++ b/logilab/common/ureports/__init__.py diff --git a/ureports/docbook_writer.py b/logilab/common/ureports/docbook_writer.py index 857068c..857068c 100644 --- a/ureports/docbook_writer.py +++ b/logilab/common/ureports/docbook_writer.py diff --git a/ureports/html_writer.py b/logilab/common/ureports/html_writer.py index eba34ea..eba34ea 100644 --- a/ureports/html_writer.py +++ b/logilab/common/ureports/html_writer.py diff --git a/ureports/nodes.py b/logilab/common/ureports/nodes.py index a9585b3..a9585b3 100644 --- a/ureports/nodes.py +++ b/logilab/common/ureports/nodes.py diff --git a/ureports/text_writer.py b/logilab/common/ureports/text_writer.py index c87613c..c87613c 100644 --- a/ureports/text_writer.py +++ b/logilab/common/ureports/text_writer.py diff --git a/urllib2ext.py b/logilab/common/urllib2ext.py index 339aec0..339aec0 100644 --- a/urllib2ext.py +++ b/logilab/common/urllib2ext.py diff --git a/vcgutils.py b/logilab/common/vcgutils.py index 9cd2acd..9cd2acd 100644 --- a/vcgutils.py +++ b/logilab/common/vcgutils.py diff --git a/visitor.py b/logilab/common/visitor.py index ed2b70f..ed2b70f 100644 --- a/visitor.py +++ b/logilab/common/visitor.py diff --git a/xmlrpcutils.py b/logilab/common/xmlrpcutils.py index 1d30d82..1d30d82 100644 --- a/xmlrpcutils.py +++ b/logilab/common/xmlrpcutils.py diff --git a/xmlutils.py b/logilab/common/xmlutils.py index d383b9d..d383b9d 100644 --- a/xmlutils.py +++ b/logilab/common/xmlutils.py @@ -40,12 +40,18 @@ except ImportError: from distutils.command.build_py import build_py -sys.modules.pop('__pkginfo__', None) # import optional features -__pkginfo__ = __import__("__pkginfo__") +__pkginfo__ = __import__("logilab.common.__pkginfo__").common.__pkginfo__ + + # import required features -from __pkginfo__ import modname, version, license, description, \ - web, author, author_email +modname = __pkginfo__.modname +version = __pkginfo__.version +license = __pkginfo__.license +description = __pkginfo__.description +web = __pkginfo__.web +author = __pkginfo__.author +author_email = __pkginfo__.author_email distname = getattr(__pkginfo__, 'distname', modname) scripts = getattr(__pkginfo__, 'scripts', []) @@ -143,16 +149,10 @@ def install(**kwargs): # install-layout option was introduced in 2.5.3-1~exp1 elif sys.version_info < (2, 5, 4) and '--install-layout=deb' in sys.argv: sys.argv.remove('--install-layout=deb') - if subpackage_of: - package = subpackage_of + '.' + modname - kwargs['package_dir'] = {package : '.'} - packages = [package] + get_packages(os.getcwd(), package) - if USE_SETUPTOOLS: - kwargs['namespace_packages'] = [subpackage_of] - else: - kwargs['package_dir'] = {modname : '.'} - packages = [modname] + get_packages(os.getcwd(), modname) - if USE_SETUPTOOLS and install_requires: + package = subpackage_of + '.' + modname + packages = get_packages(os.getcwd(), '') + if USE_SETUPTOOLS: + kwargs['namespace_packages'] = [subpackage_of] kwargs['install_requires'] = install_requires kwargs['test_require'] = test_require kwargs['dependency_links'] = dependency_links |