First of all you have two SBT plugins. The version of Scala plugin you're using already supports SBT, and you don't need an extra plugin. I recommend that you start by removing the extra plugin.
Remove unofficial plugin
To remove the unofficial plugin go to plugins configuration and remove the check next to the SBT plugin. This will not remove the plugin completely, but will keep it disabled.
Change the cache location
Once you have only single plugin, you can modify the location of the cache, by going to options, and searching for sbt. You should find an entry in IDE Settings.
You should see the VM Parameters. Click the icon next to the input, and add -Dsbt.ivy.home=D:/IvyHome/.ivy
in the last line.
Click OK and restart the IDE after saving all settings.
Now you should be using the new home location (of course this is true only for the builds run from IDE, if you use SBT from console, it will still use an old home setting).
Change the cache location for SBT ran from Console
As pointed out in the paragraph above. This change will not effect SBT ran from console. This is because by default IntelliJ uses bundled SBT.
If you want to modify your Ivy home for sbt, which you run from console, you have several ways of doing that.
I think the simplest is to modify the sbtconfig.txt
file in the SBT_HOME/conf/sbtconfig.txt
(Windows only - on Linux you'd have to modify sbtopts
).
At the end of the file add -Dsbt.ivy.home=D:/IvyHome/.ivy
.
The other way would be to modify Launcher Configuration as described in the documentation
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…