From 95951b88b55128f4cdc449ec50e0888131c40289 Mon Sep 17 00:00:00 2001 From: Brett Cannon Date: Fri, 4 Aug 2023 11:44:15 -0700 Subject: [PATCH 1/2] Document how to run under `pipx run` --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c63270b4e..08f39fb5b 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,9 @@ The `pip-compile` command lets you compile a `requirements.txt` file from your dependencies, specified in either `pyproject.toml`, `setup.cfg`, `setup.py`, or `requirements.in`. -Run it with `pip-compile` or `python -m piptools compile`. If you use +Run it with `pip-compile` or `python -m piptools compile` (or +`pipx run --spec pip-tools pip-compile` if you have +[configured](#configuration) `pip-tools` appropriately). If you use multiple Python versions, you can also run `py -X.Y -m piptools compile` on Windows and `pythonX.Y -m piptools compile` on other systems. From 52be9457a245eb8fac739e199462fefd1725599d Mon Sep 17 00:00:00 2001 From: Brett Cannon Date: Fri, 4 Aug 2023 12:40:16 -0700 Subject: [PATCH 2/2] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 08f39fb5b..3a5b897da 100644 --- a/README.md +++ b/README.md @@ -35,10 +35,10 @@ your dependencies, specified in either `pyproject.toml`, `setup.cfg`, `setup.py`, or `requirements.in`. Run it with `pip-compile` or `python -m piptools compile` (or -`pipx run --spec pip-tools pip-compile` if you have -[configured](#configuration) `pip-tools` appropriately). If you use -multiple Python versions, you can also run `py -X.Y -m piptools compile` on -Windows and `pythonX.Y -m piptools compile` on other systems. +`pipx run --spec pip-tools pip-compile` if `pipx` was installed with the +appropriate Python version). If you use multiple Python versions, you can also +run `py -X.Y -m piptools compile` on Windows and `pythonX.Y -m piptools compile` +on other systems. `pip-compile` should be run from the same virtual environment as your project so conditional dependencies that require a specific Python version,