setup.py 3.17 KB
Newer Older
Daniel Scheffler's avatar
Daniel Scheffler committed
1
2
3
#!/usr/bin/env python
# -*- coding: utf-8 -*-

4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# pyrsr, A package providing relative spectral response functions for remote sensing instruments.
#
# Copyright (C) 2019  Daniel Scheffler (GFZ Potsdam, daniel.scheffler@gfz-potsdam.de)
#
# This software was developed within the context of the GeoMultiSens project funded
# by the German Federal Ministry of Education and Research
# (project grant code: 01 IS 14 010 A-C).
#
# This program is free software: you can redistribute it and/or modify it under
# the terms of the GNU Lesser General Public License as published by the Free
# Software Foundation, either version 3 of the License, or (at your option) any
# later version.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
# details.
#
# You should have received a copy of the GNU Lesser General Public License along
# with this program.  If not, see <http://www.gnu.org/licenses/>.


Daniel Scheffler's avatar
Daniel Scheffler committed
26
27
28
29
30
31
32
33
34
35
"""The setup script."""

from setuptools import setup, find_packages

with open('README.rst') as readme_file:
    readme = readme_file.read()

with open('HISTORY.rst') as history_file:
    history = history_file.read()

Daniel Scheffler's avatar
Daniel Scheffler committed
36
37
38
version = {}
with open("pyrsr/version.py") as version_file:
    exec(version_file.read(), version)
Daniel Scheffler's avatar
Daniel Scheffler committed
39

Daniel Scheffler's avatar
Daniel Scheffler committed
40
requirements = ['numpy', 'pandas', 'matplotlib', 'scipy']
Daniel Scheffler's avatar
Daniel Scheffler committed
41

42
setup_requirements = ['setuptools-git']  # needed for package_data version controlled by GIT
Daniel Scheffler's avatar
Daniel Scheffler committed
43

44
test_requirements = ['coverage', 'nose', 'nose-htmloutput', 'rednose', 'urlchecker']
Daniel Scheffler's avatar
Daniel Scheffler committed
45

46

Daniel Scheffler's avatar
Daniel Scheffler committed
47
48
49
50
setup(
    author="Daniel Scheffler",
    author_email='daniel.scheffler@gfz-potsdam.de',
    classifiers=[
51
        'Development Status :: 4 - Beta',
Daniel Scheffler's avatar
Daniel Scheffler committed
52
        'Intended Audience :: Developers',
53
        'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)',
Daniel Scheffler's avatar
Daniel Scheffler committed
54
55
56
57
58
59
60
61
        'Natural Language :: English',
        "Programming Language :: Python :: 2",
        'Programming Language :: Python :: 2.7',
        'Programming Language :: Python :: 3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
        'Programming Language :: Python :: 3.6',
        'Programming Language :: Python :: 3.7',
Daniel Scheffler's avatar
Daniel Scheffler committed
62
        'Programming Language :: Python :: 3.8',
Daniel Scheffler's avatar
Daniel Scheffler committed
63
64
65
    ],
    description="A package providing relative spectral response functions for remote sensing instruments.",
    install_requires=requirements,
66
    license="GPL-3.0-or-later",
Daniel Scheffler's avatar
Daniel Scheffler committed
67
    long_description=readme + '\n\n' + history,
68
    package_dir={'pyrsr': 'pyrsr'},
Daniel Scheffler's avatar
Daniel Scheffler committed
69
    include_package_data=True,
70
71
    # NOTE: if the 'package_data' files are not under CVS or Subversion version control, we need setuptools-git here,
    #       otherwise they are not included in the PyPi upload content
72
    package_data={"pyrsr": ["data/**/**/*"]},
Daniel Scheffler's avatar
Daniel Scheffler committed
73
    keywords=['pyrsr', 'relative spectral response', 'remote sensing', 'sensors'],
Daniel Scheffler's avatar
Daniel Scheffler committed
74
    name='pyrsr',
75
    packages=find_packages(exclude=['tests*']),
Daniel Scheffler's avatar
Daniel Scheffler committed
76
77
78
    setup_requires=setup_requirements,
    test_suite='tests',
    tests_require=test_requirements,
Daniel Scheffler's avatar
Daniel Scheffler committed
79
80
    url='https://gitext.gfz-potsdam.de/geomultisens/pyrsr',
    version=version['__version__'],
Daniel Scheffler's avatar
Daniel Scheffler committed
81
82
    zip_safe=False,
)