diff --git a/.github/workflows/build_docs.yaml b/.github/workflows/build_docs.yaml index 03dcbbb..e8e2ad2 100644 --- a/.github/workflows/build_docs.yaml +++ b/.github/workflows/build_docs.yaml @@ -33,7 +33,8 @@ jobs: conda config --set channel_priority strict conda create -n docs python=3.10 odc-geo geopandas rasterio scipy rioxarray xarray pandoc source activate docs - python -m pip install -e .[doc] + python -m pip install -r requirements/doc.txt + python -m pip install -e . sphinx-build -b html docs/ docs/_build/ - name: Deploy 🚀 diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 5d5b4d1..5cac7c6 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -46,7 +46,8 @@ jobs: conda config --set channel_priority strict conda create -n test python=${{ matrix.python-version }} odc-geo geopandas rasterio scipy rioxarray xarray netcdf4 pandoc source activate test - python -m pip install -e .[all] + python -m pip install -r requirements/dev.txt + python -m pip install -e . - name: Check and Log Environment shell: bash diff --git a/appveyor.yml b/appveyor.yml index 6fe6259..f290dca 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -23,7 +23,8 @@ install: #------------------------------------------------------------------------------- # Install geocube #------------------------------------------------------------------------------- - - pip install .[all] + - python -m pip install -r requirements/test.txt + - python -m pip install . build: false diff --git a/pyproject.toml b/pyproject.toml index df70096..188e670 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,5 +2,65 @@ # Minimum requirements for the build system to execute. requires = ["setuptools", "wheel"] +[project] +name = "geocube" +version = "0.5.3.dev0" +description = "Tool to convert geopandas vector data into rasterized xarray data." +maintainers = [ + {name = "geocube Contributors"}, +] +keywords = [ + "GDAL", + "rasterize", + "vector", +] +readme = "README.rst" +license = {text = "BSD-3-Clause"} +classifiers = [ + "Development Status :: 4 - Beta", + "Intended Audience :: Developers", + "Natural Language :: English", + "License :: OSI Approved :: BSD License", + "Operating System :: OS Independent", + "Topic :: Scientific/Engineering :: GIS", + "Programming Language :: Python", + "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3", + "Topic :: Software Development :: Libraries :: Python Modules", + "Typing :: Typed", +] +requires-python = ">=3.10" +dependencies = [ + "appdirs", + "click>=6.0", + "geopandas>=0.7", + "odc_geo", + "rasterio>=1.3", + "rioxarray>=0.4", + "scipy", + "xarray>=0.17", + "pyproj>=2", + "numpy>=1.20", +] + +[project.urls] +homepage = "https://corteva.github.io/geocube/" +documentation = "https://corteva.github.io/geocube/" +repository = "https://github.com/corteva/geocube" +changelog = "https://corteva.github.io/geocube/stable/history.html" + +[project.scripts] +geocube = "geocube.cli.geocube:geocube" + +[tool.setuptools.packages.find] +include = ["geocube", "geocube.*"] + +[options.package_data] +geocube = [ + "py.typed", +] + [tool.black] -target_version = ['py310'] +target_version = ["py310"] diff --git a/requirements/dev.txt b/requirements/dev.txt new file mode 100644 index 0000000..05cd54f --- /dev/null +++ b/requirements/dev.txt @@ -0,0 +1,5 @@ +-r doc.txt +-r test.txt +pylint +mypy +pre-commit diff --git a/requirements/doc.txt b/requirements/doc.txt new file mode 100644 index 0000000..32f4542 --- /dev/null +++ b/requirements/doc.txt @@ -0,0 +1,3 @@ +sphinx-click +nbsphinx +sphinx_rtd_theme diff --git a/requirements/test.txt b/requirements/test.txt new file mode 100644 index 0000000..f959ae3 --- /dev/null +++ b/requirements/test.txt @@ -0,0 +1,4 @@ +pytest>=3.6 +pytest-cov +packaging +netcdf4 diff --git a/setup.cfg b/setup.cfg deleted file mode 100644 index 7508721..0000000 --- a/setup.cfg +++ /dev/null @@ -1,77 +0,0 @@ -[metadata] -author = geocube Contributors -author_email = alansnow21@gmail.com -name = geocube -version = 0.5.3.dev0 -description = Tool to convert geopandas vector data into rasterized xarray data. -keywords = geocube, GDAL, rasterize, vector -long_description = file: README.rst -long_description_content_type = text/x-rst -license = BSD license -license_files = LICENSE -platform = any -classifiers = - Development Status :: 4 - Beta - Intended Audience :: Developers - Natural Language :: English - License :: OSI Approved :: BSD License - Operating System :: OS Independent - Topic :: Scientific/Engineering :: GIS - Programming Language :: Python - Programming Language :: Python :: 3.10 - Programming Language :: Python :: 3.11 - Programming Language :: Python :: 3.12 - Programming Language :: Python :: 3 - Topic :: Software Development :: Libraries :: Python Modules - Typing :: Typed -url = https://github.com/corteva/geocube -download_url = http://python.org/pypi/geocube - -[options] -packages = find: -zip_safe = False # https://mypy.readthedocs.io/en/stable/installed_packages.html -include_package_data = True -python_requires = >=3.10 -install_requires = - appdirs - click>=6.0 - geopandas>=0.7 - odc_geo - rasterio>=1.3 - rioxarray>=0.4 - scipy - xarray>=0.17 - pyproj>=2 - numpy>=1.20 - -[options.packages.find] -include = geocube* - -[options.package_data] -geocube = - py.typed - -[options.entry_points] -console_scripts = - geocube = geocube.cli.geocube:geocube - -[options.extras_require] -doc = - sphinx-click - nbsphinx - sphinx_rtd_theme -test = - pytest>=3.6 - pytest-cov - packaging - netcdf4 -dev = - %(doc)s - %(test)s - pylint - mypy - pre-commit -all = - %(doc)s - %(test)s - %(dev)s