Skip to content

Commit

Permalink
Merge pull request #41 from jGaboardi/switch_to_pyproject
Browse files Browse the repository at this point in the history
  • Loading branch information
knaaptime committed Aug 2, 2023
2 parents 0a4719f + 2e6120f commit d6b784d
Show file tree
Hide file tree
Showing 11 changed files with 146 additions and 135 deletions.
11 changes: 0 additions & 11 deletions .coveragerc

This file was deleted.

28 changes: 28 additions & 0 deletions .github/release.yml
@@ -0,0 +1,28 @@
changelog:
exclude:
labels:
- ignore-for-release
authors:
- dependabot
categories:
- title: Bug Fixes
labels:
- bug
- title: Enhancements
labels:
- enhancement
- title: LABEL_TITLE_1
labels:
- LABEL_1
- title: LABEL_TITLE_2
labels:
- LABEL_2
- title: LABEL_TITLE_3
labels:
- LABEL_3
- title: LABEL_TITLE_999
labels:
- LABEL_999
- title: Other Changes
labels:
- "*"
28 changes: 13 additions & 15 deletions .pre-commit-config.yaml
@@ -1,16 +1,14 @@
files: "PACKAGE_NAME\/"
repos:
- repo: https://github.com/pycqa/isort
rev: 5.10.1
hooks:
- id: isort
language_version: python3
- repo: https://github.com/pycqa/flake8
rev: 6.0.0
hooks:
- id: flake8
language_version: python3
- repo: https://github.com/psf/black
rev: 22.10.0
hooks:
- id: black
language_version: python3
- repo: https://github.com/psf/black
rev: 22.12.0
hooks:
- id: black
language_version: python3
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: "v0.0.251"
hooks:
- id: ruff

ci:
autofix_prs: false
2 changes: 0 additions & 2 deletions .pylintrc

This file was deleted.

2 changes: 0 additions & 2 deletions MANIFEST.in

This file was deleted.

105 changes: 105 additions & 0 deletions pyproject.toml
@@ -0,0 +1,105 @@
[build-system]
requires = [
"setuptools>=61.0.0", "setuptools_scm[toml]>=6.2"
]
build-backend = "setuptools.build_meta"

[project]
name = "PACKAGE_NAME"
dynamic = ["version"]
maintainers = [
{name = "MAINTAINER_NAME", email = "MAINTAINER_EMAIL@gmail.com"},
]
license = {text = "BSD 3-Clause"}
description = "short <80chr description"
keywords = ["some", "key", "words"]
readme = {text = """\
Longer description; can be from README.md
""", content-type = "text/x-rst"}
classifiers = [
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Intended Audience :: Science/Research",
"Topic :: Scientific/Engineering :: GIS",
]
requires-python = ">=3.8"
dependencies = [
"numpy>=1.3",
"pandas>=1.0",
"scipy>=1.0",
]

[project.urls]
Home = "https://pysal.org/PACKAGE_NAME/"
Repository = "https://github.com/pysal/PACKAGE_NAME"

[project.optional-dependencies]
dev = [
"black",
"pre-commit",
"ruff",
]
docs = [
"nbsphinx",
"numpydoc",
"sphinx",
"sphinxcontrib-bibtex",
"sphinx_bootstrap_theme",
]
tests = [
"codecov",
"coverage",
"pytest",
"pytest-cov",
"pytest-xdist",
]
plus = [ # this section can have any name desired; there can be any number of them
"ANY_OTHER_OPTIONAL_PACKAGES"
]

[tool.setuptools.packages.find]
include = [
"PACKAGE_NAME",
"PACKAGE_NAME.*",
]

[tool.coverage.run]
omit = ["PACKAGE_NAME/test_*"]
source = ["PACKAGE_NAME"]

[tool.coverage.report]
ignore_errors = true
omit = ["PACKAGE_NAME/test_*"]

[tool.ruff]
line-length = 88
select = [ # ruff's rule codes -- https://beta.ruff.rs/docs/rules/
"F", # flake8/pyflake; required
"I", # isort; required
"UP", # upgrade checking; required
"A", # builtins; optional but strongly encouraged
"ARG", # unused arguments; optional but strongly encouraged
"E", # errors; optional but strongly encouraged
"N", # pep8 naming; optional but strongly encouraged
"W", # warnings; optional but strongly encouraged
"B", # bugbear; optional
"C4", # comprehensions; optional
"SIM", # simplify; optional
]
exclude = ["PACKAGE_NAME/test_*", "docs/*"]
target-version = "py38"
ignore = ["B006"]

[tool.black]
line-length = 88
extend-exclude = '''
(
docs/*
)
'''

3 changes: 0 additions & 3 deletions requirements.txt

This file was deleted.

6 changes: 0 additions & 6 deletions requirements_docs.txt

This file was deleted.

8 changes: 0 additions & 8 deletions requirements_tests.txt

This file was deleted.

20 changes: 0 additions & 20 deletions setup.cfg

This file was deleted.

68 changes: 0 additions & 68 deletions setup.py

This file was deleted.

0 comments on commit d6b784d

Please sign in to comment.