pyproject-to-setup


Namepyproject-to-setup JSON
Version 0.1.1 PyPI version JSON
download
home_pageNone
SummaryConvert pyproject.toml to setup.py
upload_time2025-01-05 12:06:51
maintainerNone
docs_urlNone
authorNone
requires_python>=3.12
licenseNone
keywords convert pyproject pyproject.toml setup.py setuptool
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # pyproject-to-setup

![Python Version](https://img.shields.io/badge/python-3.12%2B-blue)
![License](https://img.shields.io/badge/license-MIT-green)

Convert `pyproject.toml` to `setup.py` based on PEP 621 specification.

## Overview

A tool to help maintainers who need to support both modern Python packaging (`pyproject.toml`) and legacy packaging (`setup.py`) simultaneously. It provides flexible conversion modes and follows the PEP 621 specification.

## Installation

```bash
pip install pyproject-to-setup
```

## Quick Start

Basic usage:

```bash
# Convert pyproject.toml in current directory
pyproject-to-setup

# Show help
pyproject-to-setup --help
```

Example conversion:

```toml
# pyproject.toml
[project]
name = "spam-eggs"
version = "2020.0.0"
dependencies = ["httpx"]
requires-python = ">=3.8"
```

```python
# Generated setup.py
import setuptools

setuptools.setup(
    name="spam-eggs",
    version="2020.0.0",
    python_requires=">=3.8",
    install_requires=["httpx"],
)
```

## Features

- Convert between `pyproject.toml` and `setup.py`
- Multiple conversion modes (full, minimal, hybrid)
- Supports PEP 621 fields
- Command line interface and Python API
- Validation of input files

## Development

Requirements:

- Python 3.12+
- Docker (optional)
- Make (optional)

Basic setup:

### Using Docker

```bash
make docker-build
make docker-up
```

### Without Docker

1. Install `uv`: <https://docs.astral.sh/uv/getting-started/installation/>

   ```bash
   uv sync
   ```

## CONTRIBUTING

For contribution guidelines, please see [CONTRIBUTING.md](CONTRIBUTING.md).

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "pyproject-to-setup",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.12",
    "maintainer_email": null,
    "keywords": "convert, pyproject, pyproject.toml, setup.py, setuptool",
    "author": null,
    "author_email": "GesonAnko <59220704+Geson-anko@users.noreply.github.com>",
    "download_url": "https://files.pythonhosted.org/packages/e0/5d/0af71b4d6f46369d15b524e68eb7d8208fe841ada8752d0248c64619da55/pyproject_to_setup-0.1.1.tar.gz",
    "platform": null,
    "description": "# pyproject-to-setup\n\n![Python Version](https://img.shields.io/badge/python-3.12%2B-blue)\n![License](https://img.shields.io/badge/license-MIT-green)\n\nConvert `pyproject.toml` to `setup.py` based on PEP 621 specification.\n\n## Overview\n\nA tool to help maintainers who need to support both modern Python packaging (`pyproject.toml`) and legacy packaging (`setup.py`) simultaneously. It provides flexible conversion modes and follows the PEP 621 specification.\n\n## Installation\n\n```bash\npip install pyproject-to-setup\n```\n\n## Quick Start\n\nBasic usage:\n\n```bash\n# Convert pyproject.toml in current directory\npyproject-to-setup\n\n# Show help\npyproject-to-setup --help\n```\n\nExample conversion:\n\n```toml\n# pyproject.toml\n[project]\nname = \"spam-eggs\"\nversion = \"2020.0.0\"\ndependencies = [\"httpx\"]\nrequires-python = \">=3.8\"\n```\n\n```python\n# Generated setup.py\nimport setuptools\n\nsetuptools.setup(\n    name=\"spam-eggs\",\n    version=\"2020.0.0\",\n    python_requires=\">=3.8\",\n    install_requires=[\"httpx\"],\n)\n```\n\n## Features\n\n- Convert between `pyproject.toml` and `setup.py`\n- Multiple conversion modes (full, minimal, hybrid)\n- Supports PEP 621 fields\n- Command line interface and Python API\n- Validation of input files\n\n## Development\n\nRequirements:\n\n- Python 3.12+\n- Docker (optional)\n- Make (optional)\n\nBasic setup:\n\n### Using Docker\n\n```bash\nmake docker-build\nmake docker-up\n```\n\n### Without Docker\n\n1. Install `uv`: <https://docs.astral.sh/uv/getting-started/installation/>\n\n   ```bash\n   uv sync\n   ```\n\n## CONTRIBUTING\n\nFor contribution guidelines, please see [CONTRIBUTING.md](CONTRIBUTING.md).\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Convert pyproject.toml to setup.py",
    "version": "0.1.1",
    "project_urls": {
        "Issues": "https://github.com/Geson-anko/pyproject-to-setup/issues",
        "Repository": "https://github.com/Geson-anko/pyproject-to-setup"
    },
    "split_keywords": [
        "convert",
        " pyproject",
        " pyproject.toml",
        " setup.py",
        " setuptool"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2544aefbd727475c0ebaf913c2558ce6805dd6ce23b529d591e335b380969e9d",
                "md5": "889a5a65a6954d61e9506650c1029a97",
                "sha256": "02b9be7efac3670de1538bc5f588123b4841ab5fe597fd075b526e8d60721baa"
            },
            "downloads": -1,
            "filename": "pyproject_to_setup-0.1.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "889a5a65a6954d61e9506650c1029a97",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.12",
            "size": 8286,
            "upload_time": "2025-01-05T12:06:49",
            "upload_time_iso_8601": "2025-01-05T12:06:49.724038Z",
            "url": "https://files.pythonhosted.org/packages/25/44/aefbd727475c0ebaf913c2558ce6805dd6ce23b529d591e335b380969e9d/pyproject_to_setup-0.1.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e05d0af71b4d6f46369d15b524e68eb7d8208fe841ada8752d0248c64619da55",
                "md5": "887eb324deb96912c238538f7a491b15",
                "sha256": "389f70b615f77d8e1a39bed400c82ab17ccc8a80885f55d068dd9c42a4b8b9b0"
            },
            "downloads": -1,
            "filename": "pyproject_to_setup-0.1.1.tar.gz",
            "has_sig": false,
            "md5_digest": "887eb324deb96912c238538f7a491b15",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.12",
            "size": 26790,
            "upload_time": "2025-01-05T12:06:51",
            "upload_time_iso_8601": "2025-01-05T12:06:51.263480Z",
            "url": "https://files.pythonhosted.org/packages/e0/5d/0af71b4d6f46369d15b524e68eb7d8208fe841ada8752d0248c64619da55/pyproject_to_setup-0.1.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-01-05 12:06:51",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Geson-anko",
    "github_project": "pyproject-to-setup",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "pyproject-to-setup"
}
        
Elapsed time: 1.23852s