|
14 | 14 | import os
|
15 | 15 | from setuptools import setup, find_packages
|
16 | 16 |
|
| 17 | +reqs = [] |
| 18 | +setup_reqs = [] |
17 | 19 |
|
18 |
| -# if we are building in travis, use the build number as the sub-minor version |
19 |
| -version = "2.1" |
20 |
| -if "TRAVIS_TAG" in os.environ.keys(): |
21 |
| - version = os.environ["TRAVIS_TAG"] |
| 20 | +# ReadTheDocs, AppVeyor and Azure builds will break when trying to instal pip deps in a conda env |
| 21 | +is_rtd = "READTHEDOCS" in os.environ |
| 22 | +is_appveyor = "APPVEYOR" in os.environ |
| 23 | +is_azure = "CONDA_PY" in os.environ |
22 | 24 |
|
| 25 | +# Only include the installation dependencies if we are not running on RTD or AppVeyor |
| 26 | +if not is_rtd and not is_appveyor and not is_azure: |
| 27 | + reqs = [ |
| 28 | + "cadquery-ocp", |
| 29 | + "ezdxf", |
| 30 | + "multimethod", |
| 31 | + "nlopt", |
| 32 | + "nptyping>=2", |
| 33 | + "typish", |
| 34 | + "casadi", |
| 35 | + "path", |
| 36 | + ] |
| 37 | + |
| 38 | + setup_reqs = ["setuptools_scm"] |
23 | 39 |
|
24 | 40 | setup(
|
25 | 41 | name="cadquery",
|
26 |
| - version=version, |
27 |
| - url="https://github.com/dcowden/cadquery", |
| 42 | + use_scm_version=True, |
| 43 | + url="https://github.com/CadQuery/cadquery", |
28 | 44 | license="Apache Public License 2.0",
|
29 | 45 | author="David Cowden",
|
30 | 46 | author_email="dave.cowden@gmail.com",
|
31 | 47 | description="CadQuery is a parametric scripting language for creating and traversing CAD models",
|
32 | 48 | long_description=open("README.md").read(),
|
33 | 49 | packages=find_packages(exclude=("tests",)),
|
| 50 | + python_requires=">=3.8,<3.11", |
| 51 | + setup_requires=setup_reqs, |
| 52 | + install_requires=reqs, |
| 53 | + extras_require={ |
| 54 | + "dev": ["docutils", "ipython", "pytest", "black==19.10b0", "click==8.0.4",], |
| 55 | + "ipython": ["ipython",], |
| 56 | + }, |
34 | 57 | include_package_data=True,
|
35 | 58 | zip_safe=False,
|
36 | 59 | platforms="any",
|
|
0 commit comments