-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
37 lines (31 loc) · 905 Bytes
/
setup.py
File metadata and controls
37 lines (31 loc) · 905 Bytes
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
import setuptools
import re
with open("README.md", "r") as fh:
long_description = fh.read()
"""
name
----------------------------------
發布套件名稱,可使用字母、數字、底線和分隔線,不能與pypi.org任何套件重複
建議使用包含自己使用者名稱
version
----------------------------------
依照 PEP-440 規範可使用 X.YaM.devN.postO
a = alpha release
b = beta release
rc = release candidate
post = post-release
dev = developmental release
classifiers
----------------------------------
根據此 https://pypi.org/classifiers/ 建議進行分類此套件包
"""
metadata = {}
with open("hello_pkg/__init__.py") as fp:
exec(fp.read(), metadata)
setuptools.setup(
version=metadata['__version__'],
author=metadata['__author__'],
author_email=metadata['__email__'],
license=metadata['__license__'],
packages=setuptools.find_packages(),
)