-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathsetup.py
52 lines (44 loc) · 1.36 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
#!/usr/bin/env python3
"""
Setup script for the COWBAT package.
"""
# Standard imports
import os
import re
# Third-party imports
from setuptools import setup, find_packages
__author__ = 'adamkoziol'
# Find the version
version = {}
# Set the path of the version file
version_script = os.path.join('cowbat', 'version.py')
with open(version_script, 'r', encoding='utf-8') as version_file:
version_content = version_file.read()
version_match = re.search(
r"^__version__ = ['\"]([^'\"]*)['\"]",
version_content,
re.M
)
if version_match:
version['__version__'] = version_match.group(1)
else:
raise RuntimeError(
f"Unable to find version string in {version_script}.")
setup(
name="COWBAT",
version=version['__version__'],
include_package_data=True,
packages=find_packages(),
scripts=[
os.path.join('cowbat', 'assembly_pipeline.py'),
os.path.join('cowbat', 'assembly_typing.py'),
os.path.join('cowbat', 'validation', 'validate_cowbat.py'),
os.path.join('cowbat', 'teacup.py'),
],
license='MIT',
author='Adam Koziol',
author_email='[email protected]',
description='CFIA OLC Workflow for Bacterial Assembly and Typing',
url='https://github.com/OLC-Bioinformatics/COWBAT',
long_description=open('README.md', encoding='utf-8').read(),
)