exasol/pytest-plugins

Add workflow for releasing a single plugin

Closed this issue · 0 comments

Currently, the process for releasing a specific plugin requires the following steps.

The current ticket requests to automate this process by moving steps 4-5 to a GitHub workflow triggered by a tag being pushed to GitHub, compare file ci-cd.yml in repo saas-api-python.

  1. prepare-release, subdir of one of the plugins see PTB, nox session
  2. push, wait for CI to terminate, merge
  3. checkout main branch locally
  4. create a tag, e.g. pytest-saas-0.1.0 and push it to GitHub
  5. Run just release pytest-saas 0.1.0 to publish the release to pypi
  6. Run gh CLI tools to create a release

gh commandline :

    GITHUB_REF_NAME=$(git describe --tags --abbrev=0)
    VERSION=$(echo $GITHUB_REF_NAME | sed -e s/.*-//)
    PROJECT=$(echo $GITHUB_REF_NAME | sed -r 's/-[0-9.]+$//')
    just release $PROJECT $VERSION
    gh release create ${GITHUB_REF_NAME} \
       --title ${GITHUB_REF_NAME} \
       --notes-file ./${PROJECT}/doc/changes/changes_${VERSION}.md \
       --latest --target main \
       dist/*