how to import your own github forked library into android studio

前端 未结 5 1993
不思量自难忘°
不思量自难忘° 2021-02-01 19:12

I found a nice open library on GitHub, I imported it into my Android Studio project using Gradle dependencies, but then I realized I need to make little modifications on it.

5条回答
  •  误落风尘
    2021-02-01 20:02

    I know that this is an old post, but for someone with similar problem, if you simply want a way to change a lib and use it in your project, you can download the lib code, change it and import into your project as a module:

    1. Open your project in Android Studio
    2. Download the library (using Git, or a zip archive to unzip)
    3. Go to File > New > Import Module and import the library as a module
    4. Right-click your app in project view and select "Open Module Settings"
    5. Click the "Dependencies" tab and then the '+' button
    6. Select "Module Dependency"
    7. Select the imported module
    8. Open your build.gradle file and check that the module is listed under dependencies.

提交回复
热议问题