These are chat archives for sbt/sbt

19th
Apr 2016
Simon Hafner
@reactormonk
Apr 19 2016 10:51
is there a way to combine commands in sbt? e.g. reload;compile
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 11:32
Hi! How do you add a dependency to a plugin you use?
cxf:libraryDependencies works from sbt, but in build.sbt libraryDependencies in cxf is not found
Simon Hafner
@reactormonk
Apr 19 2016 11:34
gotta set these in plugins.sbt
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 11:35
@reactormonk I did try that first:
libraryDependencies in cxf ++= Seq(...)
cxf not found
Simon Hafner
@reactormonk
Apr 19 2016 11:39
where did you define cxf?
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 11:40
It is defined by the plugin here:
addSbtPlugin("com.ebiznext.sbt.plugins" % "sbt-cxf-wsdl2java" % "0.1.5.3-SNAPSHOT")
Dale Wijnand
@dwijnand
Apr 19 2016 11:40
@reactormonk what do you mean combine?
Simon Hafner
@reactormonk
Apr 19 2016 11:41
Put them on the same line.
Pretty sure you have to put that into a val first.
Dale Wijnand
@dwijnand
Apr 19 2016 11:43
@reactormonk ;reload;compile
Simon Hafner
@reactormonk
Apr 19 2016 11:43
ah, forgot the ; at the beginning.
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 11:49
@reactormonk This works, but then the plugin isn't loaded:
val myCxf = addSbtPlugin("com.ebiznext.sbt.plugins" % "sbt-cxf-wsdl2java" % "0.1.5.3-SNAPSHOT").settings ++ (
    libraryDependencies ++= Seq(
      "org.jvnet.jaxb2_commons" % "jaxb2-value-constructor" % "3.0",
      "org.jvnet.jaxb2_commons" % "jaxb2-fluent-api" % "3.0",
      "org.jvnet.jaxb2_commons" % "jaxb2-basics" % "0.11.0"
    )
  )
Simon Hafner
@reactormonk
Apr 19 2016 11:50
Try adding myCxf
... in a separate line
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 11:56
Nope
libraryDependencies in CxfConfig +=
in root *.sbt
not in project/*.sbt
these kind of incosistencies really bother me..
my not make it val CxfConfig = config("CxfConfig")...
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 12:07
Ah ok, its different in code and command line
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 12:26
@OlegYch thanks, that works. But the dep lib is still not propagated to wsdl2java::managedClasspath
OlegYch
@OlegYch
Apr 19 2016 12:27
try 'inspect tree wsdl2java::managedClasspath'
ie i think you need to use CxfConfig for dependency scope instead of for libraryDepencies
OlegYch
@OlegYch
Apr 19 2016 12:32
or maybe both
dunno
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 12:33
Ajapp, this one?: "CxfConfig.name,"
Marius B. Kotsbak
@mkotsbak
Apr 19 2016 12:42
@OlegYch finally yes that it was. I just added them to the normal lib deps list as this: "org.jvnet.jaxb2_commons" % "jaxb2-fluent-api" % "3.0" % CxfConfig.name
The jar file may be placed in the src/main/libs/ directory and will then be automatically picked up by sbt in order to compile your code. A valid drop in location is also test/main/libs/, if you want to narrow the scope or your unmanaged dependency.
is this true?
OlegYch
@OlegYch
Apr 19 2016 14:37
see sbt.Classpaths#findUnmanagedJars
eugene yokota
@eed3si9n
Apr 19 2016 14:47
Perry
@pfn
Apr 19 2016 14:55
Probably is, but not quite the right place where it would be set
yeah, looks like only unmanagedBase is being set to projectLayout.libs
src/test/libs doesn't work
Simon Hafner
@reactormonk
Apr 19 2016 14:59
How can I get the error message on the last test:compile? last test:compile just gives me an empty response.
Perry
@pfn
Apr 19 2016 15:01
then there was no messages on the last compile
Simon Hafner
@reactormonk
Apr 19 2016 15:01
[error] (root/test:compileIncremental) Compilation failed
Simon Hafner
@reactormonk
Apr 19 2016 15:06
Any way to redirect output to a file? I've got a ton of debug messages obscuring the one I want to read.
OlegYch
@OlegYch
Apr 19 2016 15:08
it's already redirected to somewhere in $tmp
Perry
@pfn
Apr 19 2016 15:09
find target -name out
Sam Halliday
@fommil
Apr 19 2016 15:15
I use logback, never stdout
Tim Harper
@timcharper
Apr 19 2016 16:28
@jsuereth hey josh I know you're super duper busy; could you take a quick moment to comment on this? https://github.com/sbt/sbt-pgp/pull/84#issuecomment-211966713
@eed3si9n @pfn ok, thanks. was just confused because the standard name of sbt is lib and the names mentioned were libs
any reason for that?
Perry
@pfn
Apr 19 2016 16:31
because android
the emphasis on sbt-android has never been sbt, but android
all patterns, conventions, etc. come from android where possible
Josh Suereth
@jsuereth
Apr 19 2016 16:50
@timcharper looks good to me, give me a bit and I can merge/etc.
Tim Harper
@timcharper
Apr 19 2016 17:06
@jsuereth thank you!
InTheNow
@InTheNow
Apr 19 2016 19:01
Is there a command/plugin that will give all/most of the info for a project, such as its dependencies, source repositories, published-to repositories, scalac options, "built-with-jvm", and so on ? If not, any pointers on some commands that, when combined, would give most of this? The use case is that I want to have a metadata file that goes along with a pom that has everything the pom has, plus everything else
Tim Harper
@timcharper
Apr 19 2016 19:04
@InTheNow there is sbt-dependency-graph whic gives you dependencies
InTheNow
@InTheNow
Apr 19 2016 19:05
Yep, got that one already :)
Maybe something that just dumps state data
InTheNow
@InTheNow
Apr 19 2016 19:15
Hmm - or is just there already, all the file under .../target/streams
Perry
@pfn
Apr 19 2016 20:12
what exactly is it that you want to do?
you don't need dependency graph for that, though
but sbt-buildinfo is half of the equation
probably
unless you just want a resources file, but then you need to define the format
Dale Wijnand
@dwijnand
Apr 19 2016 20:48
It's also all in the State..
Must be a way to just iterate it and print it
That's how I wrote sbt-project-graph
InTheNow
@InTheNow
Apr 19 2016 22:09
thx ;)