Skip to content

tim-group/gradle-productstore-plugin

Repository files navigation

ProductStore publication plugin

This Gradle plugin will configure a task to publish an artifact to ProductStore, and add it as a dependency of the "publish" conventional task. It is an analogue of the maven-publish plugin, but for publishing a runnable jar to our ProductStore repository.

Normal usage

import com.timgroup.gradle.productstore.ProductStorePublication

plugins {
    id "com.timgroup.productstore" version "1.0.0"
}


publishing {
    publications {
        productStore(ProductStorePublication) {
            application = "DeployableApplication"
            artifact shadowJar
        }
    }
}

In this sample, shadowJar is a task whose output is a JAR file to be deployed.

If you are deploying to ProductStore from a subproject, you would typically declare the plugin version in the root project like this:

plugins {
    id "com.timgroup.productstore" version "1.0.0" apply false
}

Then you can use the sample above in a subproject, omitting the version "1.0.0" specification.

Configuration

The plugin defines a project extension to adjust its configuration: this can be put next to the publishing block, if required. The effective default is:

productstore {
    user "productstore"
    host "productstore"
    path "/opt/ProductStore"
    identity file(System.getProperty("user.home") + "/.ssh/productstore")
}

About

Gradle plugin to publish artifacts to ProductStore

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published