ohnosequences / nisperoCLI-legacy

command line interface for nispero
0 stars 0 forks source link

conscript scala versioning #1

Open evdokim opened 11 years ago

evdokim commented 11 years ago

@eparejatobes @laughedelic I don't understand how conscript use scala version option in application config. For example here specified full version of scala ("2.9.2") and in the end I can't retrieve this application:

$ cs era7bio/md2pdf
Getting com.era7 md2pdf_2.9.2 0.1.2 ...

:: problems summary ::
:::: WARNINGS
        module not found: com.era7#md2pdf_2.9.2;0.1.2
        ::::::::::::::::::::::::::::::::::::::::::::::

        ::          UNRESOLVED DEPENDENCIES         ::

        ::::::::::::::::::::::::::::::::::::::::::::::

        :: com.era7#md2pdf_2.9.2;0.1.2: not found

        ::::::::::::::::::::::::::::::::::::::::::::::

But when I use only major version like "2.10", I have problem with scala compiler interface:

        ::::::::::::::::::::::::::::::::::::::::::::::

        ::          UNRESOLVED DEPENDENCIES         ::

        ::::::::::::::::::::::::::::::::::::::::::::::

        :: org.scala-lang#scala-compiler;2.10: not found

        :: org.scala-lang#scala-library;2.10: not found

I use latest version version of cs and install it in this way:

curl https://raw.github.com/n8han/conscript/master/setup.sh | sh
eparejatobes commented 11 years ago

I remember having some issues with this.

evdokim commented 11 years ago

@eparejatobes It seems that by default sbt use exact version in launchconfig, and these guy publish their stuff with with full versions: https://oss.sonatype.org/content/repositories/releases/net/databinder/

laughedelic commented 11 years ago

I have couple of solutions for using conscript with 2.10:

// in build.sbt

scalaVersion := "2.10.0"

scalaBinaryVersion := "2.10.0"

this is the first one. It requires not to use %% in libraryDependencies, but write explicitly "org" % "artifact_2.10" % "version". And for your tool as dependency in other projects, the other way round, with suffix _2.10.0.

Second solution was to change conscript config, see here how if curious — I've tried it for a while but then ran into some issues, which I don't remember, I think it was about using this srtifact somewhere else.. Anyway, you can try both if you want. Now I use first approach for gener8bundle and it's ok.

evdokim commented 11 years ago

@laughedelic yes, second option works fine) Also I realized that conscript is just wrapper for something like:

java -jar sbt-launch.jar @./src/main/conscript/nisperoCLI/launchconfig