Skip to content

Improved package versioning process #93

@mkrebs81

Description

@mkrebs81

Current process

The package version is automatically detected via com.palantir.git-version:

  • take the latest tag as package version
  • if the branch is not master or another release branch, or the current commit is not a tag, append the -SNAPSHOT suffix

In my opinion, this is sub-optimal:

  • you need the release tag before developing on the new version
  • if there are multiple releases branches, e.g. updated "old" versions, there may be a newer tag than the "latest" release, which may result in confusion

Proposal for improvement

  • configure the version in gradle.properties when development on a new version begins
  • each commit will create a snapshot build and publish to snapshot repository
  • when you want to create a new release...
    1. create a detached checkout of the release branch (master)
    2. remove snapshot suffix and set maven repo to release --> will be release
    3. commit the change and create a tag from that
    4. push the tag (its ancestor will be the last commit of the master branch, but following commits to master will ignore it)
    5. build and publish release

Tasks

  • manual versioning with detached commits and tags
  • gradle release plugin

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions