Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- buildscript {
- repositories {
- maven { url 'http://localhost:8081/artifactory/gradle-dev' }
- }
- dependencies {
- classpath 'org.standardout:bnd-platform:1.2.0'
- classpath "org.jfrog.buildinfo:build-info-extractor-gradle:4+"
- }
- }
- apply plugin: 'org.standardout.bnd-platform'
- apply plugin: "com.jfrog.artifactory"
- apply plugin: 'maven-publish'
- group = 'com.google.code.gson'
- version = '2.8.0'
- publishing {
- publications {
- osgiBundles(MavenPublication) {
- artifacts {
- files("build/plugins")
- }
- }
- }
- }
- artifactory {
- contextUrl = "${artifactory_contextUrl}" //The base Artifactory URL if not overridden by the publisher/resolver
- publish {
- repository {
- repoKey = 'gradle-dev-local'
- username = "${artifactory_user}"
- password = "${artifactory_password}"
- maven = true
- }
- defaults {
- publications ('osgiBundles')
- }
- }
- resolve {
- repository {
- repoKey = 'gradle-dev'
- username = "${artifactory_user}"
- password = "${artifactory_password}"
- maven = true
- }
- }
- }
- platform {
- useBndHashQualifiers = false
- defaultQualifier = ''
- bundle(group: 'com.google.code.gson', name:'gson', version:'2.8.0') {
- bnd {
- instruction 'Export-Package', 'com.google.gson,com.google.gson.stream,com.google.gson.annotations,com.google.gson.reflect'
- }
- }
- }
- gradle artifactoryPublish
- :generatePomFileForOsgiBundlesPublication
- :artifactoryPublish
- Deploying artifact: http://localhost:8081/artifactory/gradle-dev-local/com/google/code/gson/bundle-jars/2.8.0/bundle-jars-2.8.0.pom
- Deploying build descriptor to: http://localhost:8081/artifactory/api/build
- Build successfully deployed. Browse it in Artifactory under http://localhost:8081/artifactory/webapp/builds/bundle-jars/1489323863518
- +- com
- +--- google/code/gson/bundle-jars
- |+-- 2.8.0
- | +- bundle-jars.pom
- +--- maven-metadata.xml
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement