Relates to: reqstool/reqstool-client#111
For Java we create the zip file during packageand attach it so that it is uploaded during deploy.
With hatch we have targets build and publish. We can create the zip file in build and/or publish so that it's uploaded to pypi in publish.
See: https://hatch.pypa.io/1.12/plugins/publisher/reference/#hatch.publish.plugin.interface.PublisherInterface
- config in pyproject.toml
[tool.hatch.publish.publish_reqstool_zip_artifact]
dependencies = ["reqstool-python-hatch-plugin == <version>"]
# https://luftfartsverket.github.io/reqstool-java-maven-plugin/reqstool-java-maven-plugin/0.0.3/index.html#_configuration
requirementsAnnotationsFile
svcsAnnotationsFile
outputDirectory
datasetPath
failsafeReportsDir/surefireReportsDir
- Implement a plugin with corresponding hook configuration
Update docs for publish hook in README and AsciiDoc.
Relates to: reqstool/reqstool-client#111
For Java we create the zip file during
packageand attach it so that it is uploaded duringdeploy.With hatch we have targets build and publish. We can create the zip file in build and/or publish so that it's uploaded to pypi in publish.
See: https://hatch.pypa.io/1.12/plugins/publisher/reference/#hatch.publish.plugin.interface.PublisherInterface
https://github.com/luftfartsverket/reqstool-python-hatch-plugin/blob/main/src/reqstool_python_hatch_plugin/publish_hooks/publish_reqstool_zip_artifact.py
Hook into
finalizerather thaninitializehttps://github.com/luftfartsverket/reqstool-python-hatch-plugin/blob/main/src/reqstool_python_hatch_plugin/build_hook/hook.py#L49PLUGIN_NAME = "publish_reqstool_zip_artifact"Update docs for publish hook in README and AsciiDoc.