-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
88 lines (81 loc) · 2.61 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
#!/usr/bin/env python3
"""Setup script for packaging metadata-inspektor."""
from pathlib import Path
import re
from setuptools import setup, find_packages
def read(*parts):
"""Read the content of a file."""
script_path = Path(__file__).parent
with script_path.joinpath(*parts).open() as f:
return f.read()
def find_version(*parts):
"""The the version in a given file."""
vers_file = read(*parts)
match = re.search(r'^__version__ = "(\d+.\d+.\d+)"', vers_file, re.M)
if match is not None:
return match.group(1)
raise RuntimeError("Unable to find version string.")
setup(
name="metadata_inspector",
version=find_version("src", "metadata_inspector", "_version.py"),
author="Martin Bergemann",
author_email="bergemann@dkrz.de",
maintainer="Martin Bergemann",
url="https://github.com/FREVA-CLINT/metadata-inspektor.git",
description="Inspect metadata of weather/climate datasets",
long_description=read("README.md"),
license="BSD-3-Clause",
long_description_content_type="text/markdown",
include_package_data=True,
project_urls={
"Source": "https://github.com/FREVA-CLINT/metadata-inspektor",
},
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Console",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Operating System :: POSIX :: Linux",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Topic :: Scientific/Engineering :: Physics",
"Topic :: Scientific/Engineering :: Atmospheric Science",
],
packages=find_packages("src"),
package_dir={"": "src"},
entry_points={"console_scripts": ["metadata-inspector = metadata_inspector:cli"]},
install_requires=[
"cftime",
"dask[diagnostics]",
"hurry.filesize",
"h5netcdf",
"netCDF4",
"numpy>=1.20.3",
"requests",
"xarray",
],
extras_require={
"tests": [
"black",
"pytest",
"pandas",
"mock",
"numpy",
"requests-mock",
"pytest-env",
"pytest-cov",
"testpath",
"flake8",
"mypy",
"types-mock",
"types-PyYAML",
"types-requests",
"types-setuptools",
],
},
python_requires=">=3.7",
)