sbt-release icon indicating copy to clipboard operation
sbt-release copied to clipboard

First draft for an automatic README.md version update

Open muuki88 opened this issue 7 years ago • 3 comments

Hi,

This PR is a draft for the following feature:

Automatically update the version defined in the README.md to the released version

This is implemented via two additional release steps:

  1. updateReadme
  2. commitReadme

The implementation is yet missing some crucial parts

  • [ ] configurable regex to find the version definition
  • [ ] configurable README.md file ( necessary ? )
  • [ ] documentation

WDYT?

muuki88 avatar Jan 01 '18 18:01 muuki88

I'm not sure about the implementation (I'm not familiar with sbt-release internals, and the version regex seems to be a bit dangerous: that might also match non-versions or versions of other software also mentioned in the README). Perhaps it should be restricted to specific patterns (e.g. ship with patterns for sbt/maven/gradle dependency examples that match artifact names being released, extensible by users of the plugin?)

Nonetheless this would indeed be a super useful feature!

raboof avatar Jan 24 '18 10:01 raboof

Thanks a lot for your feedback :)

the version regex seems to be a bit dangerous: that might also match non-versions or versions of other software also mentioned in the README

This is absolutely true. For this reason I want to make it configurable, so every user can tailor it to its needs.

Perhaps it should be restricted to specific patterns (e.g. ship with patterns for sbt/maven/gradle dependency examples that match artifact names being released

Shipping a bunch of commonly used patterns could be a nice addition in another pull request.

muuki88 avatar Feb 16 '18 19:02 muuki88

any updates?

vladimir-popov avatar Nov 22 '20 14:11 vladimir-popov