|
3 | 3 |
|
4 | 4 | from setuptools import setup, find_packages
|
5 | 5 |
|
6 |
| -__version__ = "0.2" |
| 6 | +__version__ = "0.4.1" |
| 7 | + |
| 8 | + |
| 9 | +def read_from(file): |
| 10 | + reply = [] |
| 11 | + with io.open(os.path.join(here, file), encoding='utf8') as f: |
| 12 | + for l in f: |
| 13 | + l = l.strip() |
| 14 | + if not l: |
| 15 | + break |
| 16 | + if l[0] != '#' or l[:2] != '//': |
| 17 | + reply.append(l) |
| 18 | + return reply |
| 19 | + |
7 | 20 |
|
8 | 21 | here = os.path.abspath(os.path.dirname(__file__))
|
9 | 22 | with io.open(os.path.join(here, 'README.md'), encoding='utf8') as f:
|
10 | 23 | README = f.read()
|
11 | 24 | with io.open(os.path.join(here, 'CHANGELOG.md'), encoding='utf8') as f:
|
12 | 25 | CHANGES = f.read()
|
13 |
| -with io.open(os.path.join(here, 'requirements.txt'), encoding='utf8') as f: |
14 |
| - REQS = [] |
15 |
| - for l in f: |
16 |
| - l = l.strip() |
17 |
| - if not l: |
18 |
| - break |
19 |
| - if l[0] == '#' or l[:2] == '//': |
20 |
| - continue |
21 |
| - REQS.append(l) |
22 | 26 |
|
23 | 27 | setup(name="py-vapid",
|
24 | 28 | version=__version__,
|
|
29 | 33 | "Programming Language :: Python :: 2",
|
30 | 34 | "Programming Language :: Python :: 2.7"
|
31 | 35 | ],
|
32 |
| - keywords='vapid', |
| 36 | + keywords='vapid push webpush', |
33 | 37 | author="JR Conlin",
|
34 | 38 |
|
35 | 39 | url='https://github.com/mozilla-services/vapid',
|
36 | 40 | license="MPL2",
|
37 | 41 | test_suite="nose.collector",
|
38 | 42 | include_package_data=True,
|
39 | 43 | zip_safe=False,
|
40 |
| - tests_require=['nose', 'coverage', 'mock>=1.0.1'], |
41 | 44 | packages=find_packages(),
|
42 |
| - install_requires=REQS, |
| 45 | + package_data={'': ['README.md', 'CHANGELOG.md', |
| 46 | + 'requirements.txt', 'test-requirements.txt']}, |
| 47 | + install_requires=read_from('requirements.txt'), |
| 48 | + tests_require=read_from('test-requirements.txt'), |
43 | 49 | entry_points="""
|
44 | 50 | [console_scripts]
|
45 | 51 | vapid = py_vapid.main:main
|
|
0 commit comments