Skip to content

Commit

Permalink
Improved __version__ and setup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
danieldevriesdarcorp committed Oct 31, 2019
1 parent a92c18c commit 06a387e
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 11 deletions.
2 changes: 1 addition & 1 deletion af_opt/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"""
This file contains imports and checks to detect MPI.
"""
from .version import __version__
__version__ = "0.9.0"

# Ensure MPI is defined
try:
Expand Down
4 changes: 0 additions & 4 deletions af_opt/version.py

This file was deleted.

14 changes: 8 additions & 6 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import re

from setuptools import setup, find_packages

exec(open("af_opt/version.py").read())
__version__ = re.findall(
r"""__version__ = ["']+([0-9\.]*)["']+""", open("af_opt/__init__.py").read()
)[0]

setup(
name="Airfoil Optimizer",
Expand All @@ -17,16 +21,13 @@
"h5py<3,>=2.10.0",
"cst<2,>=1.0.1",
"differential_evolution<2,>=1.7.0",
"matplotlib<4,>=3"
"matplotlib<4,>=3",
],
url="https://github.com/daniel-de-vries/airfoil-optimizer",
download_url="https://github.com/daniel-de-vries/airfoil-optimizer/archive/v{0}.tar.gz".format(
__version__
),
keywords=[
"airfoil",
"optimization",
],
keywords=["airfoil", "optimization"],
license="MIT License",
classifiers=[
"Intended Audience :: Developers",
Expand All @@ -37,5 +38,6 @@
"Operating System :: MacOS :: MacOS X",
"Operating System :: Microsoft :: Windows",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.6",
],
)

0 comments on commit 06a387e

Please sign in to comment.