From 7557192c88e8532656bbb08e87756f2ffdae2f45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20August=C3=BDn?= Date: Wed, 1 Feb 2017 17:39:31 +0100 Subject: [PATCH] fix version reading --- .../com/avast/gradle/dockercompose/ComposeExtension.groovy | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/groovy/com/avast/gradle/dockercompose/ComposeExtension.groovy b/src/main/groovy/com/avast/gradle/dockercompose/ComposeExtension.groovy index 3b6fc17..1f2e94d 100644 --- a/src/main/groovy/com/avast/gradle/dockercompose/ComposeExtension.groovy +++ b/src/main/groovy/com/avast/gradle/dockercompose/ComposeExtension.groovy @@ -89,10 +89,11 @@ class ComposeExtension { } VersionNumber getDockerComposeVersion() { - def p = project + def p = this.project + def env = this.environment new ByteArrayOutputStream().withStream { os -> p.exec { ExecSpec e -> - e.environment = environment + e.environment = env e.commandLine composeCommand('--version') e.standardOutput = os }