-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsetup.py
59 lines (49 loc) · 1.73 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#!/usr/bin/env python3
import setuptools
import os
def reqs_from_file(src):
requirements = []
with open(src) as f:
for line in f:
line = line.strip()
if line.startswith("-r"):
add_src = line.split(' ')[1]
add_req = reqs_from_file(add_src)
requirements.extend(add_req)
elif line.startswith("-"):
# Ignore the rest of flags (e.g. -U)
requirements.append(line.split(" ", 1)[-1])
else:
requirements.append(line)
return requirements
if __name__ == "__main__":
wd = os.path.dirname(os.path.abspath(__file__))
requirements = reqs_from_file(f"{wd}/requirements.txt")
with open(f"{wd}/README.md", "r") as fh:
long_description = fh.read()
setuptools.setup(
name="neural-document-aligner",
version="1.0",
install_requires=requirements,
license="GNU General Public License v3.0",
#author=,
#author_email=,
#maintainer=,
#maintainer_email,
description="Document aligner which uses neural technologies to search matches across bilingual documents",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/bitextor/neural-document-aligner",
packages=["neural_document_aligner", "neural_document_aligner.utils"],
#classifiers=[],
#project_urls={},
package_data={
"": ["scripts/*",
]
},
entry_points={
"console_scripts": [
"neural-document-aligner = neural_document_aligner.neural_document_aligner:main_wrapper",
]
}
)