From 88cc18de92ae7a8184a8e09ed25ec720028dae2f Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Sat, 27 Jul 2024 15:12:19 +0200 Subject: [PATCH] Replaced remaining setup.py references in the code with pyproject.toml. --- platypush/install/docker/alpine.Dockerfile | 2 +- platypush/install/docker/debian.Dockerfile | 2 +- platypush/install/docker/fedora.Dockerfile | 2 +- platypush/install/docker/ubuntu.Dockerfile | 2 +- platypush/platyvenv/__init__.py | 3 +-- setup.py | 2 +- 6 files changed, 6 insertions(+), 7 deletions(-) diff --git a/platypush/install/docker/alpine.Dockerfile b/platypush/install/docker/alpine.Dockerfile index ae04336f4e..92abf62716 100644 --- a/platypush/install/docker/alpine.Dockerfile +++ b/platypush/install/docker/alpine.Dockerfile @@ -7,7 +7,7 @@ WORKDIR /var/lib/platypush RUN --mount=type=bind,source=.,target=/curdir \ apk update && \ # If the current directory is the Platypush repository, then we can copy the existing files \ - if grep 'name="platypush"' /curdir/setup.py >/dev/null 2>&1; \ + if grep 'name="platypush"' /curdir/pyproject.toml >/dev/null 2>&1; \ then \ cp -r /curdir /install; \ # Otherwise, we need to clone the repository \ diff --git a/platypush/install/docker/debian.Dockerfile b/platypush/install/docker/debian.Dockerfile index b668847951..b4da96a7a6 100644 --- a/platypush/install/docker/debian.Dockerfile +++ b/platypush/install/docker/debian.Dockerfile @@ -10,7 +10,7 @@ ENV DOCKER_CTX=1 RUN --mount=type=bind,source=.,target=/curdir \ apt update && \ # If the current directory is the Platypush repository, then we can copy the existing files \ - if grep 'name="platypush"' /curdir/setup.py >/dev/null 2>&1; \ + if grep 'name="platypush"' /curdir/pyproject.toml >/dev/null 2>&1; \ then \ cp -r /curdir /install; \ # Otherwise, we need to clone the repository \ diff --git a/platypush/install/docker/fedora.Dockerfile b/platypush/install/docker/fedora.Dockerfile index d729c9c79f..3ce87df617 100644 --- a/platypush/install/docker/fedora.Dockerfile +++ b/platypush/install/docker/fedora.Dockerfile @@ -7,7 +7,7 @@ ENV DOCKER_CTX=1 RUN --mount=type=bind,source=.,target=/curdir \ # If the current directory is the Platypush repository, then we can copy the existing files \ - if grep 'name="platypush"' /curdir/setup.py >/dev/null 2>&1; \ + if grep 'name="platypush"' /curdir/pyproject.toml >/dev/null 2>&1; \ then \ cp -r /curdir /install; \ # Otherwise, we need to clone the repository \ diff --git a/platypush/install/docker/ubuntu.Dockerfile b/platypush/install/docker/ubuntu.Dockerfile index ccb98c42b4..10b3c1b15c 100644 --- a/platypush/install/docker/ubuntu.Dockerfile +++ b/platypush/install/docker/ubuntu.Dockerfile @@ -10,7 +10,7 @@ ENV DOCKER_CTX=1 RUN --mount=type=bind,source=.,target=/curdir \ apt update && \ # If the current directory is the Platypush repository, then we can copy the existing files \ - if grep 'name="platypush"' /curdir/setup.py >/dev/null 2>&1; \ + if grep 'name="platypush"' /curdir/pyproject.toml >/dev/null 2>&1; \ then \ cp -r /curdir /install; \ # Otherwise, we need to clone the repository \ diff --git a/platypush/platyvenv/__init__.py b/platypush/platyvenv/__init__.py index 57bb78668b..393b867d30 100755 --- a/platypush/platyvenv/__init__.py +++ b/platypush/platyvenv/__init__.py @@ -91,8 +91,7 @@ class VenvBuilder(BaseBuilder): Otherwise, the source directory will be cloned from git into a temporary folder. """ - setup_py_path = os.path.join(os.getcwd(), 'setup.py') - if os.path.isfile(setup_py_path): + if os.path.isfile(os.path.join(os.getcwd(), 'pyproject.toml')): logger.info('Using local checkout of the Platypush source code') yield os.getcwd() else: diff --git a/setup.py b/setup.py index d3d237b960..c8322f1f57 100755 --- a/setup.py +++ b/setup.py @@ -17,7 +17,7 @@ def parse_deps(deps): ret = [] for dep in deps: if dep.startswith('git+'): - continue # Don't include git dependencies in the setup.py, or Twine will complain + continue # Don't include git dependencies in pip, or Twine will complain ret.append(dep)