forked from sinhrks/japandas
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
executable file
·42 lines (35 loc) · 1.08 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# -*- coding: utf-8 -*-
#!/usr/bin/env python
import codecs
import os
from setuptools import setup, find_packages
PACKAGE = 'japandas'
README = 'README.rst'
REQUIREMENTS = 'requirements.txt'
VERSION = '0.4.0.dev'
def read(fname):
# file must be read as utf-8 in py3 to avoid to be bytes
return codecs.open(os.path.join(os.path.dirname(__file__), fname), encoding='utf-8').read()
def write_version_py(filename=None):
cnt = """\
version = '%s'
"""
a = open(filename, 'w')
try:
a.write(cnt % VERSION)
finally:
a.close()
version_file = os.path.join(os.path.dirname(__file__), PACKAGE, 'version.py')
write_version_py(filename=version_file)
setup(name=PACKAGE,
version=VERSION,
description='pandas japanese extension',
long_description=read(README),
author='sinhrks',
author_email='[email protected]',
url='http://japandas.readthedocs.org/en/stable',
license = 'BSD',
packages=find_packages(),
package_data = {'japandas.tseries': ['data/*.pkl']},
install_requires=list(read(REQUIREMENTS).splitlines())
)