I am trying to create a snapshot/daily build of my Python package, using Setuptools and Build (the PEP 517 build module).
I have tried adapting this section of the Setuptools documentation: https://setuptools.pypa.io/en/latest/userguide/distribution.html#tagging-and-daily-build-or-snapshot-releases
However, none of the following commands worked:
python -m build --config-setting=--tag-date myproject
python -m build --config-setting=tag-date myproject
python -m build --tag-date myproject
The first two build the package without the version tag, while the third is an error. The results are the same when I use --tag-build
instead of --tag-date
.
How can I tell Setuptools to add the version tag, if none of the above options work?
I do not have a setup.py
, only a setup.cfg
. I cannot use setup.py bdist_wheel --tag-date
, this command will say "File not found" because setup.py
does not exist in my project.
EDIT after searching through Setuptools issue tracker, I also tried the following commands, with no success:
python -m build --config-setting=--global-options=--tag-date myproject
python -m build --config-setting=--global-options=tag-date myproject
python -m build --config-setting=global-options=--tag-date myproject
python -m build --config-setting=global-options=tag-date myproject