为什么没有任务-V列出来自.sbt全局目录的插件?

时间:2013-10-18 21:12:01

标签: sbt

为什么~/.sbt/0.13/plugins/build.sbt中定义的插件未包含在sbt tasks -V列表中?

jacek:~/oss/scalania
$ sbt about
[info] Loading global plugins from /Users/jacek/.sbt/0.13/plugins
[info] Loading project definition from /Users/jacek/oss/scalania/project
[info] Set current project to scalania (in build file:/Users/jacek/oss/scalania/)
[info] This is sbt 0.13.0
[info] The current project is {file:/Users/jacek/oss/scalania/}scalania 0.1.0-SNAPSHOT
[info] The current project is built against Scala 2.10.3
[info] Available Plugins: com.timushev.sbt.updates.UpdatesPlugin, org.sbtidea.SbtIdeaPlugin, com.typesafe.sbt.SbtGit, com.typesafe.sbt.SbtProguard, growl.GrowlingTests, de.johoop.jacoco4sbt.JacocoPlugin, com.typesafe.sbteclipse.plugin.EclipsePlugin, com.typesafe.sbt.SbtScalariform, org.scalastyle.sbt.ScalastylePlugin
[info] sbt, sbt plugins, and build definitions are using Scala 2.10.2

jacek:~/oss/scalania
$ sbt 'tasks -V idea'
[info] Loading global plugins from /Users/jacek/.sbt/0.13/plugins
[info] Loading project definition from /Users/jacek/oss/scalania/project
[info] Set current project to scalania (in build file:/Users/jacek/oss/scalania/)
No matches for regular expression 'idea'.

jacek:~/oss/scalania
$ sbt 'tasks -V' | grep -i idea

sbt-idea插件的gen-idea任务完全正常。

jacek:~/oss/scalania
$ sbt gen-idea
[info] Loading global plugins from /Users/jacek/.sbt/0.13/plugins
[info] Loading project definition from /Users/jacek/oss/scalania/project
[info] Set current project to scalania (in build file:/Users/jacek/oss/scalania/)
[info] Creating IDEA module for project 'scalania' ...
[info] Resolving org.fusesource.jansi#jansi;1.4 ...
[info] Creating IDEA module for project 'answers' ...
[info] Resolving org.fusesource.jansi#jansi;1.4 ...
[info] Creating IDEA module for project 'exercises' ...
[info] Resolving org.fusesource.jansi#jansi;1.4 ...
[info] Excluding folder target
[info] Created /Users/jacek/oss/scalania/.idea/IdeaProject.iml
[info] Created /Users/jacek/oss/scalania/.idea
[info] Excluding folder /Users/jacek/oss/scalania/target
[info] Created /Users/jacek/oss/scalania/.idea_modules/scalania.iml
[info] Excluding folder /Users/jacek/oss/scalania/answers/target
[info] Created /Users/jacek/oss/scalania/.idea_modules/answers.iml
[info] Excluding folder /Users/jacek/oss/scalania/exercises/target
[info] Created /Users/jacek/oss/scalania/.idea_modules/exercises.iml
[info] Created /Users/jacek/oss/scalania/.idea_modules/scalania-build.iml
[info] Created /Users/jacek/oss/scalania/.idea_modules/exercises-build.iml

1 个答案:

答案 0 :(得分:1)

gen-idea是一个命令,而不是一个任务。您应该在help idea的输出中看到它。