-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathsetup.py
40 lines (30 loc) · 1006 Bytes
/
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
# -*- coding: utf-8 -*-
import os
from setuptools import setup, find_packages
BASE_DIR = os.path.realpath(os.path.dirname(__file__))
def parse_requirements():
"""
@summary: 获取依赖
"""
reqs = []
if os.path.isfile(os.path.join(BASE_DIR, "requirements.txt")):
with open(os.path.join(BASE_DIR, "requirements.txt"), 'r') as fd:
for line in fd.readlines():
line = line.strip()
if line:
reqs.append(line)
return reqs
if __name__ == "__main__":
setup(
version="1.0.0",
name="demo",
description="",
cmdclass={},
packages=find_packages(),
package_data={'': ['*.txt', '*.TXT', '*.JS', 'test/*']},
install_requires=parse_requirements(),
entry_points={'console_scripts': ['demo = demo.command_line:main']},
author="test",
author_email="[email protected]",
license="Copyright(c)2010-2018 test All Rights Reserved."
)