Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android studio Gradle dependency library download url

Tags:

android

gradle

I develop android applications via Android Studio. And I would like to use 3 party libraries but I am working in a safe network which blocks all the internet except few which are specified by IT admin. I do NOT want to work with offline gradle option (Settings -> Gradle -> offline work). I would like to use gradle as if I got internet. To do that I need know which url is required, and tell IT admin open this spesific url. My question is which link or links I require ?

EDIT:

 http://jcenter.bintray.com/ 

link above is accepted answer but also links below are required for gradle

 http://download.gradle.com
 http://services.gradle.com

 http://repo.jfrog.org
like image 443
Alp Avatar asked May 04 '15 12:05

Alp


People also ask

How do you download library on Android?

Just go to Maven central and download the libraries. For example, here is Volley. Just click the download JAR button. I would strongly recommend sticking with Gradle / Maven, though, to keep consistency with versions and appropriately handle additional dependencies for the libraries you want to download.

Where does Gradle download dependencies from?

Gradle declares dependencies on JAR files inside your project's module_name /libs/ directory (because Gradle reads paths relative to the build.gradle file). This declares a dependency on version 12.3 of the "app-magic" library, inside the "com.example.android" namespace group.

Where is dependencies File in Android Studio?

Go to File > Project Structure in Android Studio. Select the app module in the Modules list on the left. Select the Dependencies tab. Click the + button on the lower left to add the dependency.

Where is the AAR File in Android Studio?

Add your AAR or JAR as a dependency Navigate to File > Project Structure > Dependencies. In the Declared Dependencies tab, click and select Jar Dependency in the dropdown. In the Add Jar/Aar Dependency dialog, first enter the path to your . aar or .


1 Answers

This depends on the repositories on which your 3'rd party libraries are hosted. The standard ones probably include Maven Central (http://repo1.maven.org/maven2) and JCenter (https://jcenter.bintray.com or http://jcenter.bintray.com/), and if you also use private repositories defined by a url (see example below) then you should include these as well.

Example for a private maven repository definition, taken from Gradle User Guide:

repositories {
    maven {
        url "http://repo.mycompany.com/maven2"
    }
}

One last note - Maven Central and JCenter urls mentioned above are taken from Gradle User Guide.

like image 56
Amnon Shochot Avatar answered Sep 21 '22 00:09

Amnon Shochot