Skip to content
Snippets Groups Projects
Unverified Commit 5eff5b8b authored by Sergio Zharinov's avatar Sergio Zharinov Committed by GitHub
Browse files

fix(gradle): Use gradle wrapper inside docker (#5598)

parent de2986fa
No related branches found
No related tags found
No related merge requests found
......@@ -508,7 +508,7 @@ Array [
exports[`manager/gradle extractPackageFile should use docker even if gradlew is available 1`] = `
Array [
Object {
"cmd": "docker run --rm -v \\"localDir\\":\\"localDir\\" -w \\"localDir\\" renovate/gradle bash -l -c \\"gradle --init-script renovate-plugin.gradle renovate\\"",
"cmd": "docker run --rm -v \\"localDir\\":\\"localDir\\" -w \\"localDir\\" renovate/gradle bash -l -c \\"./gradlew --init-script renovate-plugin.gradle renovate\\"",
"options": Object {
"cwd": "localDir",
"encoding": "utf-8",
......@@ -536,7 +536,7 @@ Array [
},
},
Object {
"cmd": "docker run --rm -v \\"localDir\\":\\"localDir\\" -w \\"localDir\\" renovate/gradle bash -l -c \\"gradle --init-script renovate-plugin.gradle renovate\\"",
"cmd": "docker run --rm -v \\"localDir\\":\\"localDir\\" -w \\"localDir\\" renovate/gradle bash -l -c \\"./gradlew --init-script renovate-plugin.gradle renovate\\"",
"options": Object {
"cwd": "localDir",
"encoding": "utf-8",
......
......@@ -24,7 +24,6 @@ import {
import { platform } from '../../platform';
import { LANGUAGE_JAVA } from '../../constants/languages';
import { DATASOURCE_MAVEN } from '../../constants/data-binary-source';
import { BinarySource } from '../../util/exec/common';
import { DatasourceError } from '../../datasource';
export const GRADLE_DEPENDENCY_REPORT_OPTIONS =
......@@ -46,8 +45,6 @@ async function getGradleCommandLine(
): Promise<string> {
const args = GRADLE_DEPENDENCY_REPORT_OPTIONS;
if (config.binarySource === BinarySource.Docker) return `gradle ${args}`;
const gradlewPath = upath.join(cwd, 'gradlew');
const gradlewExists = await exists(gradlewPath);
const gradlewExecutable = gradlewExists && (await canExecute(gradlewPath));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment