diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 9a490ee..8e94020 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -1,4 +1,4 @@ -name: Run tests +name: Tests on: pull_request: diff --git a/README.md b/README.md index b00b317..653d10b 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,11 @@ +[![tests](https://github.com/bvanelli/actualpy/workflows/Tests/badge.svg)](https://github.com/bvanelli/actualpy/actions) [![codecov](https://codecov.io/github/bvanelli/actualpy/graph/badge.svg?token=N6V05MY70U)](https://codecov.io/github/bvanelli/actualpy) +[![version](https://img.shields.io/pypi/v/actualpy.svg?color=52c72b)](https://pypi.org/project/actualpy/) +[![pyversions](https://img.shields.io/pypi/pyversions/actualpy.svg)](https://pypi.org/project/actualpy/) +[![docs](https://readthedocs.org/projects/actualpy/badge/?version=latest)](https://actualpy.readthedocs.io/) +[![codestyle](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/python/black) +[![ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) +[![PyPI - Downloads](https://img.shields.io/pypi/dm/actualpy)](https://pypistats.org/packages/actualpy) # actualpy diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..c2ac7ab --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,55 @@ +[build-system] +requires = ["setuptools>=61.0.0"] +build-backend = "setuptools.build_meta" + +[project] +name = "actualpy" +description = "Implementation of the Actual API to interact with Actual over Python." +readme = "README.md" +authors = [ + { name = "Brunno Vanelli", email = "brunnovanelli@gmail.com" } +] +requires-python = ">=3.8.0" +dependencies = [ + "requests>=2,<2.32.0", + "sqlmodel==0.0.18", + "pydantic>=2,<3", + "sqlalchemy>=1.4", + "proto-plus>=1", + "protobuf>=4", + "cryptography>=42", + "python-dateutil>=2.9.0", +] +classifiers = [ + "Programming Language :: Python", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.8", + "Programming Language :: Python :: 3.9", + "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", +] +keywords = ["actual", "actualbudget", "api", "client"] +dynamic = ["version"] + +[project.optional-dependencies] +cli = [ + "rich>=13", + "typer>=0.12.0", + "pyyaml>=6", +] + +[project.urls] +Homepage = "https://github.com/bvanelli/actualpy" +Documentation = "https://actualpy.readthedocs.io/" +Repository = "https://github.com/bvanelli/actualpy.git" +"Bug Tracker" = "https://github.com/bvanelli/actualpy/issues" + +[project.scripts] +actualpy = "actual.cli.main:app" + +[tool.setuptools.packages.find] +exclude = ["docs*", "tests*", "examples*"] + +[tool.setuptools.dynamic] +version = { attr = "actual.version.__version__" } diff --git a/setup.py b/setup.py deleted file mode 100644 index 3f5dd5c..0000000 --- a/setup.py +++ /dev/null @@ -1,27 +0,0 @@ -from setuptools import find_packages, setup - -__version__ = "" # avoid linting issues on the file, but the line below will fill in the version -exec(open("actual/version.py").read()) -setup( - name="actualpy", - version=__version__, - packages=find_packages(), - description="Implementation of the Actual API to interact with Actual over Python.", - long_description=open("README.md").read().replace("> [!WARNING]", "⚠️**Warning**: "), - long_description_content_type="text/markdown", - author="Brunno Vanelli", - author_email="brunnovanelli@gmail.com", - url="https://github.com/bvanelli/actualpy", - zip_safe=False, - project_urls={ - "Issues": "https://github.com/bvanelli/actualpy/issues", - }, - install_requires=["cryptography", "proto-plus", "python-dateutil", "requests", "sqlmodel"], - extras_require={ - "cli": ["rich", "typer", "pyyaml"], - }, - entry_points=""" - [console_scripts] - actualpy=actual.cli.main:app - """, -)