Exemplo n.º 1
0
# -*- coding: utf-8 -*-
"""
Setup file for PyWake
"""
import os
from setuptools import setup, find_packages
import pkg_resources

repo = os.path.dirname(__file__)
try:
    from git_utils import write_vers
    version = write_vers(vers_file='py_wake/__init__.py',
                         repo=repo,
                         skip_chars=1)
except Exception:
    version = '999'

try:
    from pypandoc import convert_file

    def read_md(f):
        return convert_file(f, 'rst', format='md')
except ImportError:
    print(
        "warning: pypandoc module not found, could not convert Markdown to RST"
    )

    def read_md(f):
        return open(f, 'r').read()

Exemplo n.º 2
0
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
    Setup file for wetb.
"""

import os
from git_utils import write_vers
import sys
from setuptools import setup, find_packages
import warnings

repo = os.path.dirname(__file__)
try:
    version = write_vers(vers_file='wetb/__init__.py', repo=repo, skip_chars=1)
except Warning:
    # when there is not git repo, take version string form wetb/__init__.py
    import wetb
    version = wetb.__version__

# try:
#    from pypandoc import convert_file
#    read_md = lambda f: convert_file(f, 'rst', format='md')
# except ImportError:
#    print("warning: pypandoc module not found, could not convert Markdown to RST")
#    read_md = lambda f: open(f, 'r').read()
with open("README.md", "r") as fh:
    long_description = fh.read()

from distutils.extension import Extension
Exemplo n.º 3
0
# -*- coding: utf-8 -*-
"""
Setup file for Topfarm2
"""

import os
from git_utils import write_vers
from setuptools import setup, find_packages

repo = os.path.dirname(__file__)
version = write_vers(vers_file='topfarm/__init__.py', repo=repo, skip_chars=1)


def read(fname):
    return open(os.path.join(os.path.dirname(__file__), fname)).read()


setup(
    name='topfarm',
    version=version,
    description='Topfarm - Wind farm optimization using OpenMDAO',
    long_description=read('README'),
    url='https://gitlab.windenergy.dtu.dk/TOPFARM/topfarm2',
    author='DTU Wind Energy',
    author_email='*****@*****.**',
    license='MIT',
    packages=find_packages(
        exclude=["*.examples", "*.examples.*", "examples.*", "examples"]),
    install_requires=[
        'matplotlib',  # for plotting
        'numpy',  # for numerical calculations