Skip to content

Commit

Permalink
docs: update cli.md
Browse files Browse the repository at this point in the history
  • Loading branch information
finswimmer committed Nov 27, 2024
1 parent b1b995a commit d95ea2e
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions docs/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -420,11 +420,6 @@ Alternatively, you can specify it in the `pyproject.toml` file. It means that ch
my-package = {path = "../my/path", develop = true}
```

{{% note %}}
Before poetry 1.1 path dependencies were installed in editable mode by default. You should always set the `develop` attribute explicitly,
to make sure the behavior is the same for all poetry versions.
{{% /note %}}

{{% note %}}
The `develop` attribute is a Poetry-specific feature, so it is not included in the package distribution metadata.
In other words, it is only considered when using Poetry to install the project.
Expand Down Expand Up @@ -644,10 +639,24 @@ It can also execute one of the scripts defined in `pyproject.toml`.

So, if you have a script defined like this:

{{< tabs tabTotal="2" tabID1="script-project" tabID2=script-poetry" tabName1="[project]" tabName2="[tool.poetry]">}}

{{< tab tabID="script-project" >}}
```toml
[project]
# ...
[project.scripts]
my-script = "my_module:main"
```
{{< /tab >}}

{{< tab tabID="script-poetry" >}}
```toml
[tool.poetry.scripts]
my-script = "my_module:main"
```
{{< /tab >}}
{{< /tabs >}}

You can execute it like so:

Expand Down

0 comments on commit d95ea2e

Please sign in to comment.