val packageRpm = TaskKey[File]("package-rpm", "package an rpm")
lazy val defaultArtifactTasks: Seq[TaskKey[File]] =
(packageRpm in Compile) +: Classpaths.defaultArtifactTasks
import Classpaths.{artifactDefs, packaged}
lazy val rpmSettings: Seq[Setting[_]] = Seq(
packageRpm <<= RpmKeys.rpmTask,
Keys.`package` <<= packageRpm,
publishTo <<= yumPublishTo,
publishArtifact in packageRpm := true,
artifactClassifier in packageRpm := Some("rpm"),
artifacts <<= artifactDefs(defaultArtifactTasks),
packagedArtifacts <<= packaged(defaultArtifactTasks)
)
foo > project foo-server
foo-server > package-rpm
[info] Packaging /foo/core/target/foo-core-0.0.1-SNAPSHOT.jar ...
[info] Done packaging.
[info] Packaging /foo/server/target/foo-server-0.0.1-SNAPSHOT.jar ...
[info] Done packaging.
[info] Built rpm /foo/server/target/dist/foo-server-0.0.1-SNAPSHOT-1.noarch.rpm
[success] Total time: 4 s, completed Sep 18, 2012 2:04:20 AM
foo-server > artifacts
[info] List(Artifact(foo-server,jar,jar,None,List(compile),None,Map()), Artifact(foo-server,src,jar,Some(sources),List(sources),None,Map()), Artifact(foo-server,doc,jar,Some(javadoc),List(docs),None,Map()))
foo-server > packaged-artifacts
[info] Packaging /foo/core/target/foo-core-0.0.1-SNAPSHOT.jar ...
[info] Done packaging.
[info] Generating Scala API documentation for main sources to /foo/server/target/api...
[info] Packaging /foo/server/target/foo-server-0.0.1-SNAPSHOT.jar ...
[info] Done packaging.
model contains 51 documentable templates
[info] Scala API documentation generation successful.
[info] Packaging /foo/server/target/foo-server-0.0.1-SNAPSHOT-javadoc.jar ...
[info] Done packaging.
[success] Total time: 4 s, completed Sep 18, 2012 2:08:44 AM
Hey, the native packager plugin has publishing settings you can use to rpm:publish.
See the build of http://github.com/sbt/sbt-launcher-package for an example, and ask if you need any help!
--
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/-/W84dnn87TTsJ.
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.
Hey, the native packager plugin has publishing settings you can use to rpm:publish.
See the build of http://github.com/sbt/sbt-launcher-package for an example, and ask if you need any help!
lazy val rpmSettings: Seq[Setting[_]] = Seq(
packageRpm <<= RpmKeys.rpmTask,
Keys.`package` <<= packageRpm,
Keys.publishLocal <<= publishLocal in (Rpm),
publishTo <<= GiltRpm.yumPublishTo,
publishArtifact in packageRpm := true,
artifactClassifier in packageRpm := Some("rpm")) ++ makeDeploymentSettings(Rpm, packageRpm, "rpm")
On Sep 18, 2012 3:45 AM, "Eric Bowman" <ebo...@gilt.com> wrote:
>
> You probably meant https://github.com/sbt/sbt-native-packager, right? :)
>
Not for the example :-)
>
> On Tuesday, September 18, 2012 8:39:09 AM UTC+1, Eric Bowman wrote:
>>
>> On Tuesday, September 18, 2012 2:56:13 AM UTC+1, jsuereth wrote:
>>>
>>> Hey, the native packager plugin has publishing settings you can use to rpm:publish.
>>>
>>> See the build of http://github.com/sbt/sbt-launcher-package for an example, and ask if you need any help!
>>
>>
>> Cool, thanks. I'll check it out.
>
> --
> 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/-/DePxZ92y8xEJ.
Any chance I can see more of the build?
My publishing limits to artifact name specifically so sbt.msi, sbt.rpm, etc. are all available in a versioned directory.
If you look at the publishing setting code for sbt native packager, it should give you a hint at how to define your own ivy repository layout and adjust the artifact name/version to give you what you want!
Basically, the artifact + publishedArtifact settings have to line up. If you want the rpm published from root config, modify these setting there rather than "in Rpm"
--
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/-/kXFtlWviHIgJ.
On Sep 18, 2012 3:45 AM, "Eric Bowman" <ebo...@gilt.com> wrote:
>
> You probably meant https://github.com/sbt/sbt-native-packager, right? :)
>Not for the example :-)
Does there need to be special support for redline? Let me know, I accept pull requests :-)
--
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/-/X4pNFD78CoYJ.