Initializing Gradle is taking forever on android studio for Flutter project

前端 未结 7 2280
遇见更好的自我
遇见更好的自我 2021-01-03 22:16

I\'m trying to run a hello world flutter app for the first time on my device, but when I hit run on android studio, it shows initilizing gradle, and it stays like that for m

7条回答
  •  轮回少年
    2021-01-03 23:15

    Providing an active internet connection worked for me.

    To build gradle offline,

    For Windows,

    Go to File -> Settings.

    And open the 'Build,Execution,Deployment'. Then open the

    Build Tools -> Gradle

    Then check the box -> Offline work below.

    Click the OK button.

    For Mac OS,

    go to Android Studio -> Preferences, and the rest is the same.

提交回复
热议问题