playframework / playframework/playframework
SBT-Plugin: expose sbt dependency versions to build
Nobody has claimed this yet.
- Dominant language
- Scala
- Stars
- 12.6k
- Forks
- 4k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 29
Description
My project has many submodules which I include in my main-project.. its just a way to split things up, to keep it more organised.
In those submodules, I try to keep the external dependencies to a minimum.
Some things, like Play-Cache, Play-WS or Play-JSON I need in some modules.
So what I do (until now) is to explicitly define those dependencies in my subproject`s build, like
libraryDependencies += "com.typesafe.play" %% "play-json" % "2.6.0-M6"
Those dependency versions are all stored in
https://github.com/playframework/playframework/blob/c81dbfaa4a51da8b42b69bc12efe9a63f6868553/framework/project/Dependencies.scala
However, this file is not available for me in my build.sbt file, as its not part of the sbt-plugin.
The only thing I currently have available is
https://github.com/playframework/playframework/blob/c81dbfaa4a51da8b42b69bc12efe9a63f6868553/framework/src/sbt-plugin/src/main/scala/play/sbt/PlayImport.scala (and the other classes in that package)
So, at the moment, I always have to manually adjust my various dependency versions when changing the version of the Play Plugin.
Ideally, those dependency versions would also be exposed through the Play-SBT-Plugin, so that I can refer to them in my build.
As for the example of Play-JSON: Before I could just do a
libraryDependencies += PlayImport.json .. now that its "movedExternal" I cannot refer to it.. also the version is not available for me anymore.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by comparing framework/project/Dependencies.scala with framework/src/sbt-plugin/src/main/scala/play/sbt/PlayImport.scala, focusing on how dependency versions and movedExternal entries are represented. Trace what is currently exposed to build.sbt and define the public references needed for external projects. Done means a subproject can use the Play SBT plugin to refer to these dependency versions without duplicating them.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- scala
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100