From 7272a21ec9afa0a209cafaa0972eb7ef240fbcf7 Mon Sep 17 00:00:00 2001 From: Tammo van der Heide Date: Mon, 23 Sep 2024 10:55:32 +0200 Subject: [PATCH] Migrate sktool's setup.cfg to pyproject.toml --- sktools/pyproject.toml | 36 ++++++++++++++++++++++++++++++++++-- sktools/setup.cfg | 36 ------------------------------------ sktools/setup.py | 15 --------------- 3 files changed, 34 insertions(+), 53 deletions(-) delete mode 100644 sktools/setup.cfg delete mode 100644 sktools/setup.py diff --git a/sktools/pyproject.toml b/sktools/pyproject.toml index b163f45f..0e8402c5 100644 --- a/sktools/pyproject.toml +++ b/sktools/pyproject.toml @@ -1,3 +1,35 @@ [build-system] -requires = ['setuptools', 'wheel', 'numpy', 'scipy'] -build-backend = 'setuptools.build_meta' \ No newline at end of file +requires = ["hatchling"] +build-backend = "hatchling.build" + +[project] +name = "sktools" +version = "0.3" +authors = [{name = "DFTB+ developers"},] +dependencies = ["numpy", "scipy"] +requires-python = ">=3.10" +description = "Tools to Generate Electronic SK-parameters" +license = {text = "LGPLv3+"} +classifiers = [ + "Development Status :: 4 - Beta", + "Intended Audience :: Science/Research", + "License :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)", + "Programming Language :: Python :: 3", + "Environment :: Console", + "Operating System :: OS Independent", + "Topic :: Scientific/Engineering", +] + +[project.urls] +Homepage = "http://www.dftbplus.org" +Documentation = "https://dftbplus-recipes.readthedocs.io/en/latest/" +Repository = "https://github.com/dftbplus/skprogs.git" +Issues = "https://github.com/dftbplus/skprogs/issues" + +[project.scripts] +collectspinw = "sktools.scripts.collectspinw:main" +collectwavecoeffs = "sktools.scripts.collectwavecoeffs:main" +skdiff = "sktools.scripts.skdiff:main" +skexp = "sktools.scripts.skexp:main" +skgen = "sktools.scripts.skgen:main" +skmanip = "sktools.scripts.skmanip:main" diff --git a/sktools/setup.cfg b/sktools/setup.cfg deleted file mode 100644 index 40e410a8..00000000 --- a/sktools/setup.cfg +++ /dev/null @@ -1,36 +0,0 @@ -[metadata] -name = sktools -version = 0.3 -author = DFTB+ developers -url = http://www.dftbplus.org -description = Tools to Generate Electronic SK-parameters -license = LGPL-3.0-or-later -license_files = - ../COPYING - ../COPYING.LESSER -platform = any - -[options] -include_package_data = True -package_dir = - = src -packages = - sktools - sktools.hsd - sktools.calculators - sktools.skgen - sktools.scripts -install_requires = - numpy - scipy - -[options.entry_points] -console_scripts = - collectspinw = sktools.scripts.collectspinw:main - collectwavecoeffs = sktools.scripts.collectwavecoeffs:main - skdiff = sktools.scripts.skdiff:main - skexp = sktools.scripts.skexp:main - skgen = sktools.scripts.skgen:main - skmanip = sktools.scripts.skmanip:main - -python_requires = >=3.2 diff --git a/sktools/setup.py b/sktools/setup.py deleted file mode 100644 index 7c3378a0..00000000 --- a/sktools/setup.py +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env python3 - -''' -Legacy setup.py file that gathers its -configuration from setup.cfg and pyproject.toml -''' - -try: - from setuptools import setup -except ImportError: - from distutils.core import setup - - -if __name__ == '__main__': - setup()