Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Modernization: introduce pyproject.toml for setuptools configuration (#…
…655)
- Loading branch information
1 parent
2c3e0e8
commit aacd321
Showing
6 changed files
with
85 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: test_publish | ||
|
||
|
||
# Will attempt to build + publish package in test.pypi.org | ||
# | ||
# the build can be tested if it works as expected by installing the package with: | ||
# pip install --index-url https://test.pypi.org/simple/ --no-deps recipe-scrapers | ||
# | ||
# or by inspecting the files: https://test.pypi.org/project/recipe-scrapers/#files | ||
on: workflow_dispatch | ||
|
||
jobs: | ||
test_publish: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.x" | ||
- name: Build the package | ||
run: | | ||
python -m pip install --upgrade build | ||
python -m build . | ||
- name: Publish a Python distribution to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.TEST_PYPI_API_TOKEN }} | ||
repository_url: https://test.pypi.org/legacy/ | ||
verbose: true | ||
skip_existing: true | ||
- name: Check setuptools and build versions used | ||
run: | | ||
pip list | grep setuptools | ||
pip list | grep build |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
[build-system] | ||
requires = ["setuptools"] | ||
build-backend = "setuptools.build_meta" | ||
|
||
[project] | ||
name = "recipe_scrapers" | ||
description = "Python package, scraping recipes from all over the internet" | ||
authors = [ | ||
{name = "Hristo Harsev", email = "r+pypi@hharsev.com"}, | ||
] | ||
urls = {Homepage = "https://github.com/hhursev/recipe-scrapers/"} | ||
keywords = ["python", "recipes", "scraper", "harvest", "recipe-scraper", "recipe-scrapers"] | ||
license = {text = "MIT License"} | ||
classifiers = [ | ||
"Programming Language :: Python :: 3", | ||
"License :: OSI Approved :: MIT License", | ||
"Intended Audience :: Developers", | ||
"Operating System :: OS Independent", | ||
"Topic :: Internet :: WWW/HTTP", | ||
] | ||
dynamic = ["version", "readme"] | ||
requires-python = ">= 3.6" | ||
dependencies = [ | ||
"beautifulsoup4 >= 4.10.0", | ||
"extruct >= 0.8.0", | ||
"isodate >= 0.6.1", | ||
"requests >= 2.19.1", | ||
] | ||
|
||
[tool.setuptools.packages.find] | ||
include = ["recipe_scrapers", "recipe_scrapers.*"] | ||
exclude = ["tests", "tests.*"] | ||
|
||
[tool.setuptools.dynamic] | ||
readme = {file = "README.rst"} | ||
version = {attr = "recipe_scrapers.__version__.__version__"} | ||
|
||
[tool.setuptools.package-data] | ||
recipe_scrapers = ["py.typed"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters