Skip to content

Commit

Permalink
chore: move to hatchling
Browse files Browse the repository at this point in the history
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
  • Loading branch information
henryiii committed Jun 27, 2022
1 parent 6a6832f commit 8ca4368
Show file tree
Hide file tree
Showing 8 changed files with 109 additions and 131 deletions.
5 changes: 5 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[flake8]
extend-select = B, B9
extend-ignore = E203, E501, B950
per-file-ignores =
tests/test_plot.py: B008
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,9 @@ dmypy.json

.idea

# General
.DS_Store

# Yarn (for all-contributors local running)
/node_modules/*
/package.json
Expand Down
3 changes: 2 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ repos:
- id: mypy
files: ^src
args: []
additional_dependencies: ["numpy==1.21.*", "matplotlib>=3.4", "boost-histogram~=1.2.0", "uhi~=0.3.0"]
additional_dependencies: ["numpy~=1.21.0", "matplotlib>=3.4", "boost-histogram~=1.3.1", "uhi~=0.3.1"]

- repo: https://github.com/mgedmin/check-manifest
rev: "0.48"
Expand All @@ -79,6 +79,7 @@ repos:
rev: v2.1.0
hooks:
- id: codespell
args: ["-Lhist,gaus,nd"]

- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.9.0
Expand Down
7 changes: 0 additions & 7 deletions MANIFEST.in

This file was deleted.

2 changes: 1 addition & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def pylint(session: nox.Session) -> None:
Run pylint.
"""

session.install("pylint")
session.install("pylint~=2.14.0")
session.install("-e", ".")
session.run("pylint", "src", *session.posargs)

Expand Down
102 changes: 98 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,103 @@
[build-system]
requires = ["setuptools>=45", "setuptools_scm[toml]>=3.4"]
build-backend = "setuptools.build_meta"
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"

[tool.setuptools_scm]
write_to = "src/hist/version.py"
[project]
name = "hist"
description = "Hist classes and utilities"
readme = { file = "README.md", content-type = "text/markdown" }
authors = [ {name = "Henry Schreiner", email = "henry.schreiner@cern.ch"} ]
maintainers = [ {name = "The Scikit-HEP admins", email = "scikit-hep-admins@googlegroups.com"} ]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: Scientific/Engineering :: Mathematics",
"Topic :: Scientific/Engineering :: Physics",
"Typing :: Typed",
]
keywords = [
"histogram",
"boost-histogram",
]
requires-python = ">=3.7"
dependencies = [
"boost-histogram~=1.3.1",
"histoprint>=2.2.0",
"numpy>=1.14.5",
'typing-extensions>=3.7;python_version<"3.8"',
]
dynamic = ["version"]

[project.scripts]
hist = "hist.classichist:main"

[project.urls]
Homepage = "https://github.com/scikit-hep/hist"
Documentation = "https://hist.readthedocs.io/"
"Bug Tracker" = "https://github.com/scikit-hep/hist/issues"
Discussions = "https://github.com/scikit-hep/hist/discussions"
Changelog = "https://hist.readthedocs.io/en/latest/changelog.html"

[project.optional-dependencies]
mpl = [
"matplotlib >=3.0",
"mplhep >=0.2.16",
]
plot = [
"matplotlib >=3.0",
"mplhep >=0.2.16",
"scipy >=1.4",
"iminuit >=2",
]
test = [
"pytest >=6",
"pytest-mpl >=0.12",
]
dev = [
"pytest >=6",
"pytest-mpl >=0.12",
"matplotlib >=3.0",
"mplhep >=0.2.16",
"scipy >=1.4",
"iminuit >=2",
"ipykernel",
]
docs = [
"pytest >=6",
"pytest-mpl >=0.12",
"matplotlib >=3.0",
"mplhep >=0.2.16",
"scipy >=1.4",
"iminuit >=2",
"ipython_genutils",
"nbsphinx",
"Sphinx >=3.0.0",
"sphinx_copybutton",
"sphinx_rtd_theme >=0.5.0",
"sphinx_book_theme >=0.0.38",
"ipython",
"ipykernel",
"pillow",
"uncertainties>=3",
"myst_parser>=0.14",
]


[tool.hatch]
version.source = "vcs"
build.hooks.vcs.version-file = "src/hist/version.py"

[tool.pytest.ini_options]
minversion = "6.0"
Expand Down
69 changes: 0 additions & 69 deletions setup.cfg

This file was deleted.

49 changes: 0 additions & 49 deletions setup.py

This file was deleted.

0 comments on commit 8ca4368

Please sign in to comment.