Open semih-toprak opened 2 years ago
Hi! any update on this issue? I experience the same problem - try to transform maven project to gradle one, but it fails because my laptop behind firewall and it can't reach private repos
this is the wrong project. https://github.com/gradle/gradle/issues/20596
I am trying to migrate my project from maven, but I can not access the custom company repository. Gradle connects to the central repository by default, and disregards both my maven settings.xml and init.gradle. The issue is the same as https://github.com/gradle/gradle/issues/19884 but I am using a windows machine.
Expected Behavior
Gradle should use the repository settings from init.gradle.
Current Behavior
Gradle ignores the settings and tries to access https://repo.maven.apache.org/maven2 instead and gets blocked by corporate proxy. Same settings work fine while running any other gradle command, such as build.
Context
I can not convert a maven project to gradle while behind a corporate proxy that blocks maven repos.
Steps to Reproduce (for bugs)
1- Be behind a proxy that blocks maven repos. 2- Have a maven project 3- Open maven project folder and run gradle init with init.gradle config.
Your Environment
init.gradle file:
Settings xml:
Build scan URL:
I ran gradle init --scan and got the following error:
FAILURE: Build failed with an exception.
Where: Auto-applied by using --scan
What went wrong: Plugin [id: 'com.gradle.enterprise', version: '3.8.1', artifact: 'com.gradle:gradle-enterprise-gradle-plugin:3.8.1'] was not found in any of the following sources:
Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
Plugin Repositories (could not resolve plugin artifact 'com.gradle:gradle-enterprise-gradle-plugin:3.8.1') Searched in the following repositories: Gradle Central Plugin Repository
Try:
Get more help at https://help.gradle.org
This is probably because it did not use my repo settings and got blocked by proxy.