-
Notifications
You must be signed in to change notification settings - Fork 3
/
setup.py
105 lines (93 loc) · 3.21 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
.. currentmodule:: setup.py
.. moduleauthor:: sageit <[email protected]>
This file is used to create the package we'll publish to PyPI.
"""
import importlib.util
import os
from pathlib import Path
from setuptools import setup, find_packages
from codecs import open # Use a consistent encoding.
from os import path
here = path.abspath(path.dirname(__file__))
# Get the long description from the relevant file
with open(path.join(here, 'README.md'), encoding='utf-8') as f:
long_description = f.read()
# Get the base version from the library. (We'll find it in the `version.py`
# file in the src directory, but we'll bypass actually loading up the library.)
vspec = importlib.util.spec_from_file_location(
"version",
str(Path(__file__).resolve().parent /
'jccli'/"version.py")
)
vmod = importlib.util.module_from_spec(vspec)
vspec.loader.exec_module(vmod)
version = getattr(vmod, '__version__')
# If the environment has a build number set...
if os.getenv('buildnum') is not None:
# ...append it to the version.
version = "{version}.{buildnum}".format(
version=version,
buildnum=os.getenv('buildnum')
)
install_requirements = [
"click>=7.0,<8",
"click-log>=0.3.0,<0.4.0",
"jcapiv1@git+https://github.com/TheJumpCloud/[email protected]#subdirectory=jcapiv1",
"jcapiv2@git+https://github.com/TheJumpCloud/[email protected]#subdirectory=jcapiv2",
"PyYaml>=5.1,<6.0"
]
setup(
name='jccli',
description="A Jumpcloud command line client",
long_description=long_description,
long_description_content_type="text/markdown",
packages=find_packages(
exclude=["*.unit_tests", "*.unit_tests.*", "unit_tests.*", "unit_tests", "*.integration_tests",
"*.integration_tests.*", "integration_tests.*", "integration_tests", ]),
version=version,
python_requires=">=3",
install_requires=install_requirements,
entry_points={
"console_scripts": [
'jccli = jccli.cli:cli'
]
},
license='Apache Software License', # noqa
author='sageit',
author_email='[email protected]',
# Use the URL to the github repo.
url= 'https://github.com/Sage-Bionetworks/jccli',
download_url=(
f'https://github.com/Sage-Bionetworks/'
f'jccli/archive/{version}.tar.gz'
),
keywords=[
"jccli",
"jumpcloud",
"cli",
"idp"
],
# See https://PyPI.python.org/PyPI?%3Aaction=list_classifiers
classifiers=[
# How mature is this project? Common values are
# 3 - Alpha
# 4 - Beta
# 5 - Production/Stable
'Development Status :: 4 - Beta',
# Indicate who your project is intended for.
'Intended Audience :: Developers',
'Natural Language :: English',
'Environment :: Console',
# Pick your license. (It should match "license" above.)
# noqa
'License :: OSI Approved :: Apache Software License',
# noqa
# Specify the Python versions you support here. In particular, ensure
# that you indicate whether you support Python 2, Python 3 or both.
'Programming Language :: Python :: 3.6',
],
include_package_data=True
)