Can sbt-idea generate project files based on existing ones?
-
29-10-2019 - |
Вопрос
I have been using sbt
and sbt-idea
for a while and for the most part it works perfectly - unfortunately there is one key use case where it doesn't.
The use case is when you are working on a project based on the output of gen-idea. Everything works perfect (as expected). Then you change the project setting to enable fsc
(Fast Scala Compiler) in the project settings - still good.
You need slf4s
as a dependency so you add it to the project's build.sbt
. It is not picked up by Intellij yet (expected), so you go back to your sbt console, reload
, gen-idea
. This causes Intellij to alert you to reload the project. You do as it recommends and now slf4s
is recognized by Intellij. Great, but now the project no longer has fsc
enabled because gen-idea
re-wrote your project files.
For this instance its easy enough to re-enable fsc, but in general this doesn't scale if I need to re-configure my project every time I run gen-idea.
Is there a way to tell sbt-idea
to modify the current project files instead of creating new ones each time or base the new ones on the old ones?
Нет правильного решения