sbt

Hadoop Mini Cluster Mock (MiniDFSCluster)

﹥>﹥吖頭↗ 提交于 2019-12-21 06:57:59
问题 I need your help about hadoop-minicluster I'm working with scala (with sbt) and I try to Mock calls of HDFS. I sow hadoop-minicluster for deploying a little cluster and test on it. However, when I add the sbt dependency : libraryDependencies += "org.apache.hadoop" % "hadoop-minicluster" % "3.1.0" % Test The sources are not added and I can't import the package org.apache.hadoop.hdfs.MiniDFSCluster Do you know how I can solve the problem ? Thank you for yours answers 回答1: Surprisingly, it's not

How to declare dependency on Scalding in sbt project?

徘徊边缘 提交于 2019-12-21 05:44:12
问题 I am trying to figure out how to create an build.sbt file for my own Scalding-based project. Scalding source structure has no build.sbt file. Instead it has project/Build.scala build definition. What would be the right way to integrate my own sbt project with Scalding, so I could also import it later in Eclipse with sbt-eclipse plugin? Update: For the following code: import cascading.tuple.Fields import com.twitter.scalding._ class Scan(args: Args) extends Job(args) { val output = TextLine(

Use maven plugin on SBT

给你一囗甜甜゛ 提交于 2019-12-21 05:04:11
问题 Is there anyway to use a maven plugin on SBT? 回答1: No. sbt does support pom.xml in limited way via sbt-pom-reader, but we do not support the use of maven plugins. It has its own plugin ecosystem, so maybe you could find similar one that does the job. If you need to pull in Maven plugin as a library, you would need this setting: classpathTypes += "maven-plugin" 回答2: A maven plugin is a jar file, but with packaging maven-plugin , not jar as it would be usual. But, apparently, SBT does not like

Use maven plugin on SBT

帅比萌擦擦* 提交于 2019-12-21 05:04:04
问题 Is there anyway to use a maven plugin on SBT? 回答1: No. sbt does support pom.xml in limited way via sbt-pom-reader, but we do not support the use of maven plugins. It has its own plugin ecosystem, so maybe you could find similar one that does the job. If you need to pull in Maven plugin as a library, you would need this setting: classpathTypes += "maven-plugin" 回答2: A maven plugin is a jar file, but with packaging maven-plugin , not jar as it would be usual. But, apparently, SBT does not like

SBT how to use classes from Build.sbt inside plugin Task execution

99封情书 提交于 2019-12-21 04:57:16
问题 Any classes defined in project/*.scala files are made available for use by SBT inside the build definition code. I would like those classes to be available during the execution of an SBT plugin task, but they do not appear to be available. Why is that, and how can I fix it? The specific problem I am trying to solve is adding custom rules for Scalastyle . The project does not currently support writing your own rules, but I thought I might be able to add a rule to the project/*.sbt files and

SBT how to use classes from Build.sbt inside plugin Task execution

不想你离开。 提交于 2019-12-21 04:57:08
问题 Any classes defined in project/*.scala files are made available for use by SBT inside the build definition code. I would like those classes to be available during the execution of an SBT plugin task, but they do not appear to be available. Why is that, and how can I fix it? The specific problem I am trying to solve is adding custom rules for Scalastyle . The project does not currently support writing your own rules, but I thought I might be able to add a rule to the project/*.sbt files and

Build-automation - sbt: Compile/Test against multiple dependencies

别等时光非礼了梦想. 提交于 2019-12-21 04:12:43
问题 We just published parts of our library (Mango) which is a Scala wrapper around Google Guava common libraries for Java. The library currently depends on Google Gauva 14.0, but we would like to add support for other versions as well. Is there a way in sbt, a build-automation tool for Scala and Java projects, to create maven like profiles, where each profile compiles against a different version of the respective Guava dependency, so we can include it in the continuous integration test matrix?

sbt 0.12.4 - there were x feature warning(s); re-run with -feature for details

只愿长相守 提交于 2019-12-21 04:09:05
问题 I get an error there were 15 feature warning(s); re-run with -feature for details : $ /usr/local/sbt/bin/sbt [info] Loading project definition from /home/alex/Documents/projects/my_app123/project [info] Set current project to sbt-android (in build file:/home/alex/Documents/projects/my_app123/) > compile -feature [error] Expected end of input. [error] compile -feature [error] ^ > sbt-version [info] 0.12.4 > compile [warn] Credentials file /home/alex/.ivy2/.credentials does not exist [info]

How to skip javadoc dependency download with sbt

爷,独闯天下 提交于 2019-12-21 04:02:26
问题 1) Javadoc artifacts tend to take too much space and time to download. For example, scala-library-2.10.2-sources.jar is 1 Mb, but scala-library-2.10.2-javadoc.jar is 34 Mb. 2) Javadoc is mostly not needed at all. As modern IDEs can fetch all info from sources. So I wanted to find a way to alter sbt settings to completely disable javadoc download among third-party library dependencies. 回答1: https://github.com/mpeltonen/sbt-idea/issues/225#issuecomment-19150022 kindly gives the answer: The

Why sbt compile doesn't copy unmanaged resources to classpath?

感情迁移 提交于 2019-12-21 03:53:34
问题 Could you tell me why sbt compile doesn't copy unmanaged resources to classpath? On the other hand sbt package does. As result I can't start debugging unless I invoke package call manually :( I'm using SBT 0.12.1 Below is my build.sbt. import AssemblyKeys._ // put this at the top of the file net.virtualvoid.sbt.graph.Plugin.graphSettings assemblySettings organization := "com.zzz" version := "0.1" scalaVersion := "2.10.2" scalacOptions := Seq("-unchecked", "-language:reflectiveCalls,postfixOps