From 95ca88b7bcd69a5b1da725f18678e65ce8a76f8a Mon Sep 17 00:00:00 2001 From: RobertoRoos Date: Tue, 23 Jul 2024 13:21:59 +0200 Subject: [PATCH] Added missing mention of type = "file" reference in [tool.poetry.scripts] (#9510) --- docs/pyproject.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/docs/pyproject.md b/docs/pyproject.md index 3533a7106e6..09387125cbe 100644 --- a/docs/pyproject.md +++ b/docs/pyproject.md @@ -737,7 +737,17 @@ Here, we will have the `my_package_cli` script installed which will execute the When a script is added or updated, run `poetry install` to make them available in the project's virtualenv. {{% /note %}} -### extras +```toml +[tool.poetry.scripts] +my_executable = { reference = "some_binary.exe", type = "file" } +``` + +With this configuration, Poetry will look for the referenced file in the active project and then copy it to the OS installation directory. + +* On Windows the file is placed in the `Scripts/` directory. +* On *nix system the file is placed in the `bin/` directory. + +## `extras` **Deprecated**: Use `project.optional-dependencies` instead.