Skip to content

Commit f9f7f57

Browse files
authored
Merge pull request #44 from pradal/namespace
Namespace
2 parents 294beb5 + 2e82593 commit f9f7f57

File tree

37 files changed

+167
-472
lines changed

37 files changed

+167
-472
lines changed

container

image/setup.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
from setuptools import setup, find_packages
1+
from setuptools import setup, find_namespace_packages
22
#from openalea.deploy.metainfo import read_metainfo
33

44
#metadata = read_metainfo('metainfo.ini', verbose=True)
55
#for key, value in zip(metadata.keys(), metadata.values()):
66
# exec("%s = '%s'" % (key, value))
77

88
name = 'openalea.image'
9-
version = '2.2.0' # TODO: replace by a version.py
109
description = 'Image manipulation'
1110
long_description = description+ ' for VisuAlea from the OpenAlea platform.'
1211
authors = 'Jerome Chopard, Eric Moscardi and Christophe Pradal'
@@ -15,14 +14,19 @@
1514
license = 'Cecill-C'
1615

1716
pkg_root_dir = 'src'
18-
packages = find_packages('src')
17+
packages = find_namespace_packages(where='src', include=['openalea.*'])
1918
package_dir = dict([('', 'src')])
2019

2120
# Meta information
2221
long_description = '''
2322
Image contains algorithms to play with data images
2423
and visualea nodes to wrap numpy algorithms
2524
'''
25+
# find version number in src/openalea/image/version.py
26+
_version = {}
27+
with open("src/openalea/image/version.py") as fp:
28+
exec(fp.read(), _version)
29+
version = _version["__version__"]
2630

2731
###########
2832
#

image/src/openalea/__init__.py

Lines changed: 0 additions & 8 deletions
This file was deleted.

stdlib/src/openalea/version.py renamed to image/src/openalea/image/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
MAJOR = 2
99
"""(int) Version major component."""
1010

11-
MINOR = 0
11+
MINOR = 1
1212
"""(int) Version minor component."""
1313

1414
POST = 0

numpy/setup.py

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,12 @@
11
# -*- coding: utf-8 -*-
22
"""setup file for stdlib package"""
3-
__revision__ = "$Id: $"
43

54
import os
6-
from setuptools import setup, find_packages
7-
8-
__license__ = 'Cecill-C'
9-
__revision__ = "$Id: $"
5+
from setuptools import setup, find_namespace_packages
106

117
pj = os.path.join
128

13-
# find version number in src/openalea/core/version.py
9+
# find version number in src/openalea/numpy_wralea/version.py
1410
_version = {}
1511
with open("src/openalea/numpy_wralea/version.py") as fp:
1612
exec(fp.read(), _version)
@@ -27,8 +23,7 @@
2723
url = 'https://github.com/openalea/openalea-components'
2824
license = 'Cecill-C'
2925

30-
pkgs = find_packages('src')
31-
packages = pkgs
26+
packages = find_namespace_packages(where='src', include=['openalea.*'])
3227
package_dir = {'':'src'}
3328

3429
setup_requires = ['openalea.deploy']

numpy/src/openalea/__init__.py

Lines changed: 0 additions & 8 deletions
This file was deleted.

numpy/src/openalea/numpy_wralea/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
MAJOR = 2
77
"""(int) Version major component."""
88

9-
MINOR = 1
9+
MINOR = 2
1010
"""(int) Version minor component."""
1111

1212
POST = 0

pandas/metainfo.ini

Lines changed: 0 additions & 14 deletions
This file was deleted.

pandas/setup.cfg

Lines changed: 0 additions & 44 deletions
This file was deleted.

pandas/setup.py

Lines changed: 28 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,40 @@
11
# -*- coding: utf-8 -*-
22
"""setup file for pandas package"""
3-
__revision__ = "$Id$"
43

54
import os
6-
from setuptools import setup, find_packages
7-
8-
__license__ = 'Cecill-C'
9-
__revision__ = "$Id$"
10-
11-
pj = os.path.join
12-
13-
from openalea.deploy.metainfo import read_metainfo
14-
metadata = read_metainfo('metainfo.ini', verbose=True)
15-
for key,value in metadata.iteritems():
16-
exec("%s = '%s'" % (key, value))
17-
18-
pkgs = [ pkg for pkg in find_packages('src') if namespace not in pkg]
19-
top_pkgs = [pkg for pkg in pkgs if len(pkg.split('.')) < 2]
20-
packages = [ namespace + "." + pkg for pkg in pkgs]
21-
package_dir = dict( [('','src')] + [(namespace + "." + pkg, "src/" + pkg) for pkg in top_pkgs] )
5+
from setuptools import setup, find_namespace_packages
6+
# find version number in src/openalea/core/version.py
7+
_version = {}
8+
with open("src/openalea/pandas_wralea/version.py") as fp:
9+
exec(fp.read(), _version)
10+
version = _version["__version__"]
11+
12+
name = "OpenAlea.Pandas"
13+
description = "Pandas modules for Visualea."
14+
long_description = "Interfaces some of the `Pandas <http://pandas.pydata.org/>`_ functionalities as nodes in VisuAlea."
15+
authors = "Christophe Pradal"
16+
authors_email = "christophe.pradal at cirad.fr"
17+
url = "http://openalea.rtfd.io"
18+
license = "Cecill-C"
19+
20+
packages = find_namespace_packages(where='src', include=['openalea.*'])
2221

2322
setup(
2423
name=name,
2524
version=version,
26-
description=description,
27-
long_description = '',
28-
author = authors,
29-
author_email = authors_email,
30-
url = url,
31-
license = license,
32-
33-
namespace_packages = ['openalea'],
34-
create_namespaces=True,
35-
zip_safe=False,
36-
37-
packages=packages,
38-
39-
package_dir=package_dir,
40-
41-
# Add package platform libraries if any
42-
include_package_data=True,
25+
description=description,
26+
author=authors,
27+
author_email=authors_email,
28+
url=url,
29+
license=license,
30+
31+
packages = packages,
32+
package_dir={ '' : 'src' },
33+
include_package_data = True,
34+
zip_safe = False,
4335
package_data = {'' : ['*.csv'],},
4436

45-
# Dependencies
46-
setup_requires = ['openalea.deploy'],
47-
install_requires = ['openalea.core', 'pandas'],
48-
dependency_links = ['http://openalea.gforge.inria.fr/pi'],
49-
50-
# entry_points
5137
entry_points = {
5238
"wralea": ['openalea.pandas = openalea.pandas_wralea'],
53-
},
54-
55-
)
39+
}
40+
)

0 commit comments

Comments
 (0)