diff options
| author | Aaron LI <aaronly.me@outlook.com> | 2016-09-27 11:34:57 +0800 | 
|---|---|---|
| committer | Aaron LI <aaronly.me@outlook.com> | 2016-09-27 11:34:57 +0800 | 
| commit | 8db11a101a16ce66ec5c03f21a50f939beeb9003 (patch) | |
| tree | 119f1bee0428afff3a31d8e33dc2a85a837af651 | |
| parent | a256581869584f37d5f0ea04cd2907a9604a0d12 (diff) | |
| download | fg21sim-8db11a101a16ce66ec5c03f21a50f939beeb9003.tar.bz2 | |
Rewrite setup.py and update __init__.py accordingly
| -rw-r--r-- | fg21sim/__init__.py | 5 | ||||
| -rwxr-xr-x | setup.py | 35 | 
2 files changed, 18 insertions, 22 deletions
| diff --git a/fg21sim/__init__.py b/fg21sim/__init__.py index 1ea6cf7..b829e5b 100644 --- a/fg21sim/__init__.py +++ b/fg21sim/__init__.py @@ -6,12 +6,15 @@ Realistic Foregrounds Simulation for EoR 21cm Signal Detection  :license: MIT  """ -__title__ = "fg21sim" +__pkgname__ = "fg21sim"  __version__ = "0.0.1"  __author__ = "Weitian LI" +__author_email__ = "liweitianux@live.com"  __license__ = "MIT"  __copyright__ = "Copyright (c) 2016 Weitian LI"  __url__ = "https://github.com/liweitianux/fg21sim" +__description__ = ("Realistic Foregrounds Simulation for " +                   "EoR 21cm Signal Detection")  # Set default logging handle to avoid "No handler found" warnings. @@ -1,29 +1,22 @@  #!/usr/bin/env python3 -# -*- coding: utf-8 -*- - -import re  from setuptools import setup, find_packages +import fg21sim as pkg -with open('fg21sim/__init__.py') as f: -    version = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]', -                        f.read(), re.MULTILINE).group(1) - -with open('README.rst') as f: -    readme = f.read() - -with open('LICENSE') as f: -    license = f.read()  setup( -    name='fg21sim', -    version=version, -    description='Realistic Foregrounds Simulation for EoR 21cm Signal Detection', -    long_description=readme, -    author='Weitian LI', -    author_email='liweitianux@live.com', -    url='https://github.com/liweitianux/fg21sim', -    license=license, -    packages=find_packages(exclude=('tests', 'docs')) +    name=pkg.__pkgname__, +    version=pkg.__version__, +    description=pkg.__description__, +    long_description=open("README.rst").read(), +    author=pkg.__author__, +    author_email=pkg.__author_email__, +    url=pkg.__url__, +    license=pkg.__license__, +    packages=find_packages(exclude=("tests", "docs")), +    scripts=[ +        "bin/healpix2hpx", +        "bin/hpx2healpix", +    ],  ) | 
