setup.py 2.72 KB
Newer Older
1 2 3
#!/usr/bin/env python
# -*- coding: utf-8 -*-

4

Gero Müller's avatar
Gero Müller committed
5
from setuptools import setup
6
import os
7

8
ignore_extensions = [".py", ".pyc", ".pyo", ".orig"]
9
files = []
10
packages = []
11

12 13
srcdir = os.path.dirname(os.path.abspath(__file__))

14
for wroot, wdirs, wfiles in os.walk("vispa"):
15
    for name in wfiles:
16 17
        if name == "__init__.py":
            packages.append(wroot.replace(os.sep, ".").strip(". \t\n\r"))
18
        base, ext = os.path.splitext(name)
Gero Müller's avatar
Gero Müller committed
19
        if ext not in ignore_extensions:
20
            files.append(os.path.join(wroot[6:], name))
21

Gero Müller's avatar
Gero Müller committed
22 23
versions_path = os.path.join("vispa", "models", "alembic", "versions")
for wroot, wdirs, wfiles in os.walk(versions_path):
24 25
    for name in wfiles:
        if name.endswith(".py"):
Gero Müller's avatar
Gero Müller committed
26
            files.append(os.path.join(wroot[6:], name))
27

Gero Müller's avatar
Gero Müller committed
28 29
# http://stackoverflow.com/a/24517154
version_ns = {}
30
version_path = os.path.join(srcdir, 'vispa', 'version.py')
Gero Müller's avatar
Gero Müller committed
31 32 33
with open(version_path) as version_file:
    exec(version_file.read(), version_ns)

34 35
setup(
    name="vispa",
Gero Müller's avatar
Gero Müller committed
36
    version=version_ns['__version__'],
37 38 39 40 41
    description="VISPA - Integrated Development Environment for Physicists",
    author="VISPA Project",
    author_email="vispa@lists.rwth-aachen.de",
    url="http://vispa.physik.rwth-aachen.de/",
    license="GNU GPL v2",
42
    packages=packages,
43
    package_data={"vispa": files},
44
    scripts=[os.path.join(srcdir, 'bin', 'vispa'), os.path.join(srcdir, 'bin', 'vispad'), os.path.join(srcdir, 'bin', 'vispa-ldap-export')],
45 46 47 48 49 50 51 52 53 54 55
    install_requires=[
        "sqlalchemy >= 0.9.0",
        "mako",
        "cherrypy<9.0.0", # cherrypy removed wsgiserver, see https://github.com/Lawouach/WebSocket-for-Python/issues/205
        "paramiko",
        "rpyc>3.3.0", 
        "alembic >= 0.7.3",  # for Operations.batch_alter_table
        "passlib",
        "ws4py",
        "ldap3"
    ],
56 57 58
    dependency_links=[
      'https://github.com/geromueller/rpyc/archive/master.zip#egg=rpyc-3.4.0',
    ],
59
    extras_require={"doc": ["sphinx", "sphinx-bootstrap-theme"]},
60
    classifiers=[
Gero Müller's avatar
Gero Müller committed
61
        "Development Status :: 5 - Production/Stable",
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77
        "Environment :: Web Environment",
        "Framework :: CherryPy",
        "Intended Audience :: Developers",
        "Intended Audience :: Education",
        "Intended Audience :: Information Technology",
        "Intended Audience :: Science/Research",
        "Intended Audience :: System Administrators",
        "License :: OSI Approved :: GNU General Public License v2 (GPLv2)",
        "Natural Language :: English",
        "Operating System :: MacOS",
        "Operating System :: POSIX",
        "Programming Language :: JavaScript",
        "Programming Language :: Python",
        "Topic :: Internet",
        "Topic :: Scientific/Engineering",
        "Topic :: Software Development",
78
    ]
79
)