0

I am working on Android Studio and Want to make projects offline.

InsaneCat
  • 2,115
  • 5
  • 21
  • 40
Raj Raghav
  • 11
  • 2
  • Refer this: [Download and install Android studio gradle offline](https://stackoverflow.com/questions/50291289/download-and-install-android-studio-gradle-offline/50291708#50291708). – Ali Mar 14 '20 at 04:42
  • 4
    Does this answer your question? [Does Android studio need internet connection to build project](https://stackoverflow.com/questions/21746087/does-android-studio-need-internet-connection-to-build-project) – InsaneCat Mar 14 '20 at 05:09

2 Answers2

0

You don't need to connect to internet for running every app. You just need to have some libraries, when you don't have them, you should connect to internet to download them.

MMG
  • 3,226
  • 5
  • 16
  • 43
0

You need to understand how gradle works , so when you sync it checks your module level build.gradle file and see if there are some dependencies code for which is not available and if it is not available it downloads it from

buildscript {  // you will find it in project level build.gradle file
repositories {
    google()
    jcenter()

}

with the buildscript closure as shown above, Gradle will notice that you do not have this dependency. It will then download that artifact from Google, as Google serves up its plugin from its own site nowadays.

The repositories closure inside the buildscript closure indicates where plugins can come from. Here, jcenter() is a built-in method that teaches Gradle about JCenter, a popular location for obtaining open source libraries. Similarly, google() is a built-in method that teaches Gradle about a site where it can download plugins from Google.

So in order to download something you need internet right? you also can see downloading ....etc... it comes written at bottom in android studio when you're syncing

That is what i know , there is still plenty of stuff left , go grab it , good luck

Abhinav Chauhan
  • 1,304
  • 1
  • 7
  • 24