Importing github projects as library to existing project
android-studio, github
Solution
I already explained in this post how to use a project library in android studio. But I know especially at the beginning it's not that easy until you understand the structur of AS-Projects. So here an explanation for your issue:
I'm adding project libraries to my projects by configuring the gradle files of my project like this:
- create a folder in your root project directory named 'libs'
- copy the complete folder 'library' of the SlidingMenu project on git into 'libs'
- rename the folder 'library' that you just copied to e.g. "SlidingMenuLibrary" (just to avoid confusion)
now add this library in your `settings.gradle` with the following command:
include ':libs:SlidingMenuLibrary'
go to your `build.gradle` file of your AppProject and add the following line to your 'dependencies':
compile project(':libs:SlidingMenuLibrary')
at least you have to sync your gradle files: Tools -> Android -> Sync Project with Gradle Files
Please try this. If you get errors please post the log file.
Problem
I am used to importing library as .jar file but I don't know how to use the projects from github like this: https://github.com/jfeinstein10/SlidingMenu/ I want to use it in my existing project. I tried including the project file in the dependencies but it's giving me some errors