Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move project setup to pyproject.toml and build package with "build". #1325

Merged
merged 3 commits into from Jan 2, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/publish.yml
Expand Up @@ -58,11 +58,11 @@ jobs:
python-version: '3.10'
- name: Install dependencies
run: |
pip install setuptools wheel twine
pip install build twine
- name: Publish
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
run: |
python setup.py sdist bdist_wheel
python -m build
twine upload dist/*
19 changes: 14 additions & 5 deletions MANIFEST.in
@@ -1,7 +1,16 @@
include CONTRIBUTORS.txt
include LICENSE.txt
include MANIFEST.in
include README.rst
recursive-include crispy_forms/static *
recursive-include crispy_forms/templates *
recursive-include crispy_forms/tests *.py *.html
include *.md
include *.txt
include *.yaml
include Makefile
include tox.ini
include .editorconfig

graft crispy_forms
graft docs
graft tests
graft requirements

prune docs/_build
global-exclude *.pyc
43 changes: 43 additions & 0 deletions pyproject.toml
@@ -1,3 +1,46 @@
[build-system]
requires = ["setuptools>=61.0"]
build-backend = "setuptools.build_meta"

[project]
name = "django-crispy-forms"
requires-python = ">=3.7"
description = "Best way to have Django DRY forms"
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Framework :: Django :: 3.2",
"Framework :: Django :: 4.0",
"Framework :: Django :: 4.1",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: JavaScript",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Software Development :: Libraries :: Python Modules",
]
license = {text = "MIT"}
dependencies = ["django>=3.2"]
authors = [{name = "Miguel Araujo", email = "miguel.araujo.perez@gmail.com"}]
dynamic = ['version']
readme = "README.rst"
keywords = ["forms", "django", "crispy", "DRY"]

[project.urls]
"Homepage" = "https://github.com/django-crispy-forms/django-crispy-forms"
"Issues" = "https://github.com/django-crispy-forms/django-crispy-forms/issues"
"Changelog" = "https://github.com/django-crispy-forms/django-crispy-forms/releases"

[tool.setuptools.dynamic]
version = {attr = "crispy_forms.__version__"}

[tool.black]
line-length = 119
target-version = ['py37']
Expand Down
57 changes: 0 additions & 57 deletions setup.py

This file was deleted.