I do not find any way to make an executable script via pyproject.toml
. All I found is to use old setup.cfg
file. The official documentation says nothing about that.
Suppose you simply create a function as a official documention does:
def add_one(number):
return number + 1
and you want to have this (save it as src/example_package_YOUR_USERNAME_HERE/myscript.py
following the example in the documentation)
from example_package_YOUR_USERNAME_HERE import example
example.add_one(2)
as executable. How to do that?