From 03a30deffc4d08fdea420bd74962b556d41b081e Mon Sep 17 00:00:00 2001 From: Josselin Chevalay Date: Thu, 18 Feb 2021 16:12:44 +0100 Subject: [PATCH] Update gradle disable leftShift method Change-Id: Iddda0007cfaedea6575a618e1e9b25c7fc52bd21 --- build.gradle | 2 +- gradle/wrapper/gradle-wrapper.properties | 2 +- .../plugin/gradle/rust/RustPlugin.groovy | 24 +++++++------------ 3 files changed, 10 insertions(+), 18 deletions(-) diff --git a/build.gradle b/build.gradle index 3f5e228..aa74849 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,5 @@ group 'com.arielcabib' -version '0.1.1' +version '0.1.2' buildscript { repositories { diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index a0c49f8..de6a7bf 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.2-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-4.9-all.zip diff --git a/src/main/java/com/arielcabib/plugin/gradle/rust/RustPlugin.groovy b/src/main/java/com/arielcabib/plugin/gradle/rust/RustPlugin.groovy index 8860dcc..57447fa 100644 --- a/src/main/java/com/arielcabib/plugin/gradle/rust/RustPlugin.groovy +++ b/src/main/java/com/arielcabib/plugin/gradle/rust/RustPlugin.groovy @@ -2,6 +2,7 @@ package com.arielcabib.plugin.gradle.rust import org.gradle.api.Plugin import org.gradle.api.Project +import org.gradle.api.tasks.Exec /** * Created by ariel on 17/05/15. @@ -9,26 +10,17 @@ import org.gradle.api.Project class RustPlugin implements Plugin { @Override void apply(Project project) { - project.task('rustBuild') << { - println "Cargo building" - project.exec { - commandLine 'cargo', 'build' - } + project.tasks.create('rustBuild', Exec).configure { + commandLine 'cargo', 'build' } - project.task('rustRun') << { - println "Cargo running" - project.exec { - standardInput System.in - commandLine 'cargo', 'run' - } + project.tasks.create('rustRun', Exec).configure { + standardInput System.in + commandLine 'cargo', 'run' } - project.task('rustUpdate') << { - println "Cargo updating" - project.exec { - commandLine 'cargo', 'update' - } + project.tasks.create('rustUpdate', Exec).configure { + commandLine 'cargo', 'update' } } }