When I first learned Scala 3 years ago, I didn’t think too much about its main build tool – SBT. In fact, my main project throughout this time was a mixed Java-Scala project which started with Maven and later migrated to Gradle (by me). It’s not until recently that I’ve started to really think about this question, and it certainly seems that others have been wondering about it as well; not all that surprising given that there is seemingly no formal addressing to the topic.
Perhaps I am a bit ignorant of the full SBT experience, but I couldn’t easily come up with any major advantages that it has over its Java world alternatives (Maven / Gradle). The incremental compiler (Zinc) surely has no real alternative, but I don’t entirely consider it as an integral part of SBT as a build platform (and I believe this thought is reflected with the separation of Zinc to its own repository). Given no clear advantages, what is the justification for keeping SBT alive and advocating it as the main build tool for Scala?
Scala doesn’t exist on its own - it relies heavily on Java tools and libraries, and a big part of its community consists of developers who either came to Scala from Java, or are involved in Java projects as well (or both). As one of those developers, there is no reality in which I will not be familiar with at least one of the popular build tools in the Java world (Maven / Gradle), and having to learn an entirely new tool just makes my work harder.
This is in fact a criticism I share with other Scala oriented tools which already have alternatives in the Java world, such as ScalaMock trying to replace Mockito. Why implement a whole new library when it is possible to extend over Mockito – a widely used Java tool? In fact, someone has recently started a new Mockito-Scala project in order to do just that. The funny thing is that this new project maintains two build configurations – SBT and Gradle (build tool of the original Mockito project) – and for what?
I would honestly prefer it if the attention of both the Scala community and its main contributors would focus on integrating Scala and its inherently exclusive tools (such as Zinc) with existing build tools. This means adding a full support to both Maven and Gradle, and not just a flaky plugin that doesn’t even integrate with the new Zinc compiler. I find it quite absurd that I have to work on my own example project of Gradle mixed with Java and Scala (still WIP).
This is both an open question to the more experienced members here and (hopefully) the beginning of an honest discussion on the subject.