Skip to content

Commit

Permalink
Merge pull request #179 from KOLANYCH-libs:pyproject.toml
Browse files Browse the repository at this point in the history
Implements migration to PEP 621-compliant pyproject.toml.

Merge conflicts were manually resolved (the list of the supported
Python versions have changed since the time of the pull request).
  • Loading branch information
astanin committed Oct 6, 2022
2 parents 9172378 + 9d32480 commit 6e37802
Show file tree
Hide file tree
Showing 7 changed files with 59 additions and 66 deletions.
10 changes: 10 additions & 0 deletions .circleci/config.yml
Expand Up @@ -39,6 +39,16 @@ jobs:
- ./venv
key: v1-dependencies-{{ checksum ".circleci/requirements.txt" }}

- run:
name: build wheel
command: |
. venv/bin/activate
python -m build -nwx .
- store_artifacts:
path: dist
destination: dist

- run:
name: run tests
command: |
Expand Down
5 changes: 5 additions & 0 deletions .circleci/requirements.txt
Expand Up @@ -3,3 +3,8 @@ tox
numpy
pandas
wcwidth
setuptools
pip
build
wheel
setuptools_scm
2 changes: 2 additions & 0 deletions .gitignore
@@ -1,3 +1,5 @@
/tabulate/version.py

build
dist
.tox
Expand Down
7 changes: 3 additions & 4 deletions HOWTOPUBLISH
@@ -1,8 +1,7 @@
# update contributors and CHANGELOG in README
# tag version release
python3 benchmark.py # then update README
tox -e py33,py34,py36-extra
python3 setup.py sdist bdist_wheel
tox -e py37-extra,py38-extra,py39-extra,py310-extra
python3 -m build -nswx .
twine upload --repository-url https://test.pypi.org/legacy/ dist/*
twine upload dist/*
# tag version release
# bump version number in setup.py in tabulate.py
38 changes: 38 additions & 0 deletions pyproject.toml
@@ -0,0 +1,38 @@
[build-system]
requires = ["setuptools>=61.2.0", "wheel", "setuptools_scm[toml]>=3.4.3"]
build-backend = "setuptools.build_meta"

[project]
name = "tabulate"
authors = [{name = "Sergey Astanin", email = "s.astanin@gmail.com"}]
license = {text = "MIT"}
description = "Pretty-print tabular data"
readme = "README.md"
classifiers = [
"Development Status :: 4 - Beta",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Topic :: Software Development :: Libraries",
]
requires-python = ">=3.7"
dynamic = ["version"]

[project.urls]
Homepage = "https://github.com/astanin/python-tabulate"

[project.optional-dependencies]
widechars = ["wcwidth"]

[project.scripts]
tabulate = "tabulate:_main"

[tool.setuptools]
packages = ["tabulate"]

[tool.setuptools_scm]
write_to = "tabulate/version.py"
61 changes: 0 additions & 61 deletions setup.py

This file was deleted.

2 changes: 1 addition & 1 deletion tabulate.py → tabulate/__init__.py
Expand Up @@ -22,7 +22,7 @@ def _is_file(f):


__all__ = ["tabulate", "tabulate_formats", "simple_separated_format"]
__version__ = "0.8.11"
from .version import version as __version__ # noqa: F401


# minimum extra space in headers
Expand Down

0 comments on commit 6e37802

Please sign in to comment.