scala-steward icon indicating copy to clipboard operation
scala-steward copied to clipboard

Ability to update semanticdbVersion defined in build.sbt

Open exoego opened this issue 5 years ago • 1 comments

This idea came up on my mind on https://github.com/scalacenter/scalafix/issues/1183

sbt-scalafix automatically downloads semanticdb-scalac specified by semanticdbVersion property. sbt-scalafix defines the default semanticdb-scalac version in scalafixSemanticdb.revision property. However, sometimes the scalameta version in scalafixSemanticdb.revision is incompatible with newer Scala. So, users may need to set semanticdbVersion explicitly , like below:

inThisBuild(
  List(
    semanticdbEnabled := true,
    // semanticdbVersion := scalafixSemanticdb.revision, 
    semanticdbVersion := "4.3.18", 
    Configs.isProductionRelease := false
  )
)

However, this is not good since the version need manual update when newer version of scalameta/sbt-scalafix are published.

I think Scala Steward can save such manual updating semanticdbVersion, like doing so on scalafmt or sbt.

exoego avatar Jul 01 '20 00:07 exoego

Sounds good to me. Should we wait until https://github.com/scalacenter/scalafix/issues/1146 is resolved? If I understand that correctly it will be possible in the future to set the Scalafix version (and therefore the semanticdb version) in .scalafix.conf similar to how the Scalafmt version is set in .scalafmt.conf. The implementation for this feature could then be similar to the existing implementation for Scalafmt.

fthomas avatar Jul 02 '20 19:07 fthomas