Closed edublancas closed 1 year ago
Acceptance criteria:
.toml
filetoml
then resort to default logic.kub-dashboard
A few clarifications:
version_package
parameter in version
method)version.py
file of kub-dashboard
reside? I see a setup.py
file with version in cloud-core
. Do we want separate version files for api
and cloud-core
?
@edublancas so if I add this pyproject.toml:
[tool.pkgmt]
version_file = 'cloud-core/src/cloud_core/__init__.py'
It should work. However, note that the changelog is still in the root directory: https://github.com/ploomber/kub-dashboard/blob/main/CHANGELOG.md and that should still work, since commands like pkgmt version
rely on the CHANGELOG.md to reside in the root folder
In previous releases, we allowed
pkgmt version
to work in projects that don't have asetup.py
; however, I'm having issues making it work with https://github.com/ploomber/kub-dashboardI suggest the following:
If there is a
pyproject.toml
file with the following:(you can load the pyproject.toml with the code in config.py)
Let's use that file as the "version file"
If pyproject.toml doesn't exist or if the
version_file
key doesn't exist. let's use the default logic where we look up the project root and then use theproject_root/__version__.py
file.let's make sure the full workflow works because I had to add some if statements in versioneer.py (line 142) in a previous PR since I was getting some errors.
I think we can modify VersioneerNonSetup and have something like
VersioneerNonSetup(version_file='path/to/version.py')
(and assume the project root is the git repository root)