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

com.github.ozsie.StringExtensions.kt Maven / Gradle / Ivy

The newest version!
package com.github.ozsie

import org.apache.maven.model.Plugin
import java.io.File

internal fun StringBuilder.buildPluginPaths(plugins: ArrayList, mdp: Plugin, root: String) {
    plugins.forEach { plugin ->
        if (File(plugin).exists()) {
            append(plugin).append(SEMICOLON)
        } else {
            mdp.dependencies
                    ?.filter { plugin == it.getIdentifier() }
                    ?.forEach { append(it asPath root).append(SEMICOLON) }
        }
    }
}

internal fun String.asPath() = replace(DOT, SLASH)




© 2015 - 2024 Weber Informatics LLC | Privacy Policy