Skip to content

Commit

Permalink
DevOps: Adopt PEP 621 and use pyproject.toml
Browse files Browse the repository at this point in the history
PEP 621 introduces the `pyproject.toml` file which is now the
recommended way for defining a project with its build and install
dependencies. In addition, it allows to provide configuration for
various tools, such as tox, instead of using individual files for each
tool.

The `MANIFEST.in` file is no longer required since the build backend
`flit` will automatically include all files, except those explicitly
marked with `[tool.flit.sdist] exclude`.

The description is added to the `__init__.py` of the package and it is
marked as `dynamic` in the `pyproject.toml` which will automatically
fetch it from the package docstring.
  • Loading branch information
sphuber committed Nov 3, 2022
1 parent 204a04b commit 3018394
Show file tree
Hide file tree
Showing 5 changed files with 74 additions and 78 deletions.
5 changes: 0 additions & 5 deletions MANIFEST.in

This file was deleted.

2 changes: 1 addition & 1 deletion aiida_nwchem/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# -*- coding: utf-8 -*-
"""aiida-nwchem package"""
"""The official AiiDA plugin for NWChem"""
__version__ = '2.1.0'
73 changes: 73 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,76 @@
[build-system]
requires = ['flit_core>=3.4,<4']
build-backend = 'flit_core.buildapi'

[project]
name = 'aiida-nwchem'
dynamic = ['description', 'version']
authors = [
{name = 'The AiiDA team', email = 'developers@aiida.net'}
]
readme = 'README.md'
license = {file = 'LICENSE.txt'}
classifiers = [
'Development Status :: 4 - Beta',
'Framework :: AiiDA',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX :: Linux',
'Operating System :: MacOS :: MacOS X',
'Programming Language :: Python',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Topic :: Scientific/Engineering'
]
keywords = ['aiida', 'workflows', 'nwchem']
requires-python = '>=3.6'
dependencies = [
'aiida-core[atomic_tools]>=1.2.1',
'numpy',
]

[project.urls]
Source = 'https://github.com/aiidateam/aiida-nwchem'

[project.optional-dependencies]
docs = [
'sphinx',
'sphinxcontrib-contentui',
'sphinxcontrib-details-directive',
'sphinx-rtd-theme',
'sphinxcontrib-napoleon',
]
pre-commit = [
'pre-commit~=2.17',
]
tests = [
'pgtest~=1.3',
'pytest~=6.2',
'pytest-regressions~=1.0',
]

[project.entry-points.'aiida.calculations']
'nwchem.nwchem' = 'aiida_nwchem.calculations.nwchem:NwchemCalculation'
'nwchem.base' = 'aiida_nwchem.calculations.nwchem:NwchemBaseCalculation'

[project.entry-points.'aiida.parsers']
'nwchem.nwchem' = 'aiida_nwchem.parsers.nwchem:NwchemBaseParser'

[project.entry-points.'aiida.workflows']
'nwchem.base' = 'aiida_nwchem.workflows.base:NwchemBaseWorkChain'

[tool.flit.module]
name = 'aiida_nwchem'

[tool.flit.sdist]
exclude = [
'.github/',
'docs/',
'tests/',
'.gitignore',
'.pre-commit-config.yaml',
]

[tool.flynt]
line-length = 120
fail-on-change = true
Expand Down
56 changes: 0 additions & 56 deletions setup.json

This file was deleted.

16 changes: 0 additions & 16 deletions setup.py

This file was deleted.

0 comments on commit 3018394

Please sign in to comment.