All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.xbib.gradle.plugin.elasticsearch.VersionProperties.groovy Maven / Gradle / Ivy

Go to download

Gradle plugins for the developer kit for building and testing Elasticsearch and Elasticsearch plugins

The newest version!
package org.xbib.gradle.plugin.elasticsearch

/**
 * Accessor for dependency versions used by this plugin.
 */
class VersionProperties {

    static final Map versions = [:]

    static {
        Properties props = new Properties()
        InputStream propsStream = VersionProperties.class.getResourceAsStream('/gradle.properties')
        if (propsStream) {
            props.load(propsStream)
        }
        for (String property : props.stringPropertyNames()) {
            versions.put(property, props.getProperty(property))
        }
    }

    static String getVersion(String name) {
        versions.get(name + '.version')
    }

    static Map getAllVersions() {
        versions.collectEntries { k, v -> [(k.replace('.version', '')): v]}
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy