diff options
author | Li Haoyi <haoyi.sg@gmail.com> | 2017-11-15 10:11:48 -0800 |
---|---|---|
committer | Li Haoyi <haoyi.sg@gmail.com> | 2017-11-15 10:11:48 -0800 |
commit | 3f768a3a0407c1b331199abea5fdd6d970da7615 (patch) | |
tree | 7f8e712bd5be1f3d797cbdc07f04e676bff9fa1b | |
parent | 225a12f993307fc7f4d9e6e42df905623d849fb2 (diff) | |
download | mill-3f768a3a0407c1b331199abea5fdd6d970da7615.tar.gz mill-3f768a3a0407c1b331199abea5fdd6d970da7615.tar.bz2 mill-3f768a3a0407c1b331199abea5fdd6d970da7615.zip |
Mark the scala library jar as `type=Scala` to make intellij believe it is a scala sdk
-rwxr-xr-x | build.sc | 4 | ||||
-rw-r--r-- | scalaplugin/src/main/scala/mill/scalaplugin/GenIdea.scala | 6 |
2 files changed, 5 insertions, 5 deletions
@@ -1,6 +1,6 @@ #!/usr/bin/env amm -import $cp.out.ScalaPlugin.assembly -//import $cp.scalaplugin.target.`scala-2.12`.`mill-scalaplugin-assembly-0.1-SNAPSHOT.jar` +//import $cp.out.ScalaPlugin.assembly +import $cp.scalaplugin.target.`scala-2.12`.`mill-scalaplugin-assembly-0.1-SNAPSHOT.jar` import ammonite.ops.pwd import mill._ import mill.scalaplugin.{Module, Dep, TestRunner} diff --git a/scalaplugin/src/main/scala/mill/scalaplugin/GenIdea.scala b/scalaplugin/src/main/scala/mill/scalaplugin/GenIdea.scala index c503aae7..eca36184 100644 --- a/scalaplugin/src/main/scala/mill/scalaplugin/GenIdea.scala +++ b/scalaplugin/src/main/scala/mill/scalaplugin/GenIdea.scala @@ -46,7 +46,7 @@ object GenIdea { Tuple2(".idea"/"misc.xml", miscXmlTemplate()), Tuple2( ".idea"/"modules.xml", - modulesXmlTemplate( + allModulesXmlTemplate( for((path, mod) <- modules) yield path.mkString(".").toLowerCase ) @@ -100,7 +100,7 @@ object GenIdea { </project> } - def modulesXmlTemplate(selectors: Seq[String]) = { + def allModulesXmlTemplate(selectors: Seq[String]) = { <project version="4"> <component name="ProjectModuleManager"> <modules> @@ -130,7 +130,7 @@ object GenIdea { } def libraryXmlTemplate(name: String, url: String) = { <component name="libraryTable"> - <library name={name}> + <library name={name} type={if(name.contains("org_scala-lang_scala-library_")) "Scala" else null}> <CLASSES> <root url={url}/> </CLASSES> |