Skip to main content

pyproject2ebuild

pyproject2ebuild is a tool to automatically convert Python pyproject.toml metadata into Gentoo ebuild files. It can openrate on a local pyproject.toml or fetch it for you.

Features

  • Parses project name, version, description, license, homepage
  • Converts Python dependencies to Gentoo dependency syntax
  • Auto-maps version constraints
  • Auto-generate metadata.xml
  • Compatible with setuptools and setuptools_scm
  • GPL-3.0-or-later licensed

Example:

$ pyproject2ebuild https://raw.githubusercontent.com/pyupio/safety/refs/heads/main/pyproject.toml
Downloaded pyproject.toml from https://raw.githubusercontent.com/pyupio/safety/refs/heads/main/pyproject.toml
Ebuild written to ./safety-3.4.0.ebuild


$ cat safety-3.4.0.ebuild
# Copyright 2025
# Distributed under the terms of the GNU General Public License v2

EAPI=8

PYTHON_COMPAT=( python3_11 python3_12 )

inherit distutils-r1

DESCRIPTION="Scan dependencies for known vulnerabilities and licenses."
HOMEPAGE=""
SRC_URI="https://pypi.io/packages/source/s/safety/safety-3.4.0.tar.gz"

LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"

DEPEND="
	>=dev-python/authlib-1.2.0[${PYTHON_USEDEP}]
	>=dev-python/click-8.0.2[${PYTHON_USEDEP}]
	>=dev-python/dparse-0.6.4[${PYTHON_USEDEP}]
	>=dev-python/filelock-3.16.1[${PYTHON_USEDEP}]
	>=dev-python/jinja2-3.1.0[${PYTHON_USEDEP}]
	>=dev-python/marshmallow-3.15.0[${PYTHON_USEDEP}]
	>=dev-python/packaging-21.0[${PYTHON_USEDEP}]
	>=dev-python/psutil-6.1.0[${PYTHON_USEDEP}]
	>=dev-python/pydantic-2.6.0[${PYTHON_USEDEP}]
	<dev-python/pydantic-2.10.0[${PYTHON_USEDEP}]
	dev-python/requests[${PYTHON_USEDEP}]
	dev-python/httpx[${PYTHON_USEDEP}]
	dev-python/tenacity[${PYTHON_USEDEP}]
	=dev-python/safety-schemas-0.0.14[${PYTHON_USEDEP}]
	>=dev-python/setuptools-65.5.1[${PYTHON_USEDEP}]
	>=dev-python/typer-0.12.1[${PYTHON_USEDEP}]
	>=dev-python/typing-extensions-4.7.1[${PYTHON_USEDEP}]
	>=dev-python/nltk-3.9[${PYTHON_USEDEP}]
	dev-python/tomlkit[${PYTHON_USEDEP}]
"
RDEPEND="${DEPEND}"

Release files for pyproject2ebuild 0.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyproject2ebuild 0.0.4
File Size Uploaded
pyproject2ebuild-0.0.4.tar.gz 27.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyproject2ebuild 0.0.4
File Interpreter ABI Platform
pyproject2ebuild-0.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 47.9 kB

Release files / pyproject2ebuild-0.0.4.tar.gz

Download URL pyproject2ebuild-0.0.4.tar.gz
Size 27.7 kB
Tags Source
SHA-256 checksum
How to use checksums
fd666997f9365d0309df6a5f856cc7ad7af6e0e8347b2dcd4e3f04451666f834
BLAKE2b-256 checksum
How to use checksums
f1257f3b582bc6cd74c96451fcf10a5ac35a0e51aff4463e3c0c28f27a474164
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.11.12

Release files / pyproject2ebuild-0.0.4-py3-none-any.whl

Download URL pyproject2ebuild-0.0.4-py3-none-any.whl
Size 20.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4d06cf7de1b5f95d984da14d278325cd189745bf219a193e7318d643816eb6ce
BLAKE2b-256 checksum
How to use checksums
225855b88060405fffe6b5dc3c96572d0c326052885d430f495cfc12ce6b48e2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.11.12

Release history Release notifications | RSS feed

This release

0.0.4 This release

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page