Re: [sbt] Adding custom Ivy artifacts to project build.

217 views
Skip to first unread message

Jesse C

unread,
Aug 14, 2012, 9:47:42 AM8/14/12
to simple-b...@googlegroups.com
So these are from a Build.scala file.

// This creates the artifact.  This designates the name and extension of the artifact and the configurations which is belongs to.
lazy val jzmqArtifact = Artifact("jzmq", "jar", "jar", None, Configurations.Compile :: Nil, None)

// Create my custom settings
lazy val mySettings = Seq[Setting[_]](
 // My custom settings/tasks go here
) ++
addArtifact(jzmqArtifact, jzmqJar) // The first argument is the name of the artifact.  The second argument is a Task that returns a File.  That file is what will be published as the artifact.

lazy val project = Project(id = "project",
                                     base = file("."),
                                     settings = mySettings) // Add the settings to my project.

On Mon, Aug 13, 2012 at 3:47 PM, Alexei <ale...@gmail.com> wrote:
Hello!

I need to publish to Ivy a few files in addition to the main .jar file. We have ivy.xml file that gets imported by SBT, and I added artifact definitions there.

Now I need to make sure they get picked up by publish-local, and I could not find what I should add to build.sbt for this to happen.

I found mentions of addArtifact in the docs, but I am likely using it wrong.

Thank you,
Alexei

--
You received this message because you are subscribed to the Google Groups "simple-build-tool" group.
To view this discussion on the web visit https://groups.google.com/d/msg/simple-build-tool/-/veCFGPPaQRMJ.
To post to this group, send email to simple-b...@googlegroups.com.
To unsubscribe from this group, send email to simple-build-t...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/simple-build-tool?hl=en.


Reply all
Reply to author
Forward
0 new messages