http://d.hatena.ne.jp/seratch2/20120406/1333693373
上記の手順の通り入れると、
ユーザーのホーム/.conscript/harrah/xsbt/sbt/launchconfig
に以下のようなファイルができてる。
[scala] version: 2.9.1 [app] org: org.scala-tools.sbt name: sbt version: read(sbt.version)[0.11.2] class: ${sbt.main.class-sbt.xMain} components: xsbti cross-versioned: true [repositories] local [organization] maven-central scala-tools-releases scala-tools-snapshots [ivy] ivy-home: ${sbt.ivy.home-${user.home}/.ivy2/} [boot] directory: /Users/kenji/.conscript/boot ~/
"Error during sbt execution: Invalid section(s): organization"
というのは、上記のファイルの
[organization]
という部分がおかしい(launchconfigファイルの仕様として、そんなsectionが存在しない)ということ。そもそもこのlaunchconfigというのはどこからもってきたか*1というとこれ
https://github.com/harrah/xsbt/blob/v0.11.2/src/main/conscript/sbt/launchconfig
ためしに、これを
wget https://raw.github.com/harrah/xsbt/v0.11.2/src/main/conscript/sbt/launchconfig mv launchconfig ~/.conscript/harrah/xsbt/sbt/
として、書き換えると、ちゃんと起動する。
なんで、こうなってしまっているかというと、(たぶん)このあたりのparseのやり方
https://github.com/n8han/conscript/blob/0.3.4/src/main/scala/launchconfig.scala#L108
行の中に [ と ] で囲まれているものがあるかどうかで判断しているけど、launchconfigの仕様はもっと複雑で、sbt本体ではこんな感じでやっている
https://github.com/harrah/xsbt/blob/v0.11.2/launch/ConfigurationParser.scala
だぶん、conscriptのやり方だと、sectionではない部分をsectionと認識してしまって、間違ったファイルを出力してしまっているんじゃないかとおもう。
そもそもこのparseする部分は、(可能ならば) sbt のものをそのまま利用するべきではないか?
そこまで深くソース追っていないので、予想間違ってるかもしれませんが、大雑把に見たところ、原因はこんな感じではないかと。
ざっと見たところ、このblog書いてる現在issue登録されていないっぽい。英語力あれだし、もうちょっとちゃんと検証してからissue報告する or だれかわかりやすくまとめて issue 報告してくれないかな|ω・`)チラッ