com.ullink.NuGetPlugin.groovy Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gradle-nuget-plugin Show documentation
Show all versions of gradle-nuget-plugin Show documentation
Gradle plugin for NuGet, to package, upload artifacts and restore packages.
package com.ullink
import org.gradle.api.Plugin
import org.gradle.api.Project
import org.gradle.api.Task;
import org.gradle.api.plugins.BasePlugin;
import org.gradle.internal.os.OperatingSystem
class NuGetPlugin implements Plugin {
void apply(Project project) {
project.apply plugin: 'base'
if (OperatingSystem.current().windows) {
def nuget = project.task('nugetPack', type: NuGetPack)
nuget.group = BasePlugin.BUILD_GROUP
nuget.description = 'Executes nuget pack command.'
nuget = project.task('nugetPush', type: NuGetPush)
nuget.group = BasePlugin.UPLOAD_GROUP
nuget.description = 'Executes nuget push command.'
nuget = project.task('nugetRestore', type: NuGetRestore)
nuget.group = BasePlugin.BUILD_GROUP
nuget.description = 'Executes nuget package restore command.'
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy