问题
Let's use Yalantis Phoenix Library as an example. I don't want to import the project via gradle, but I want to edit and use the source code of the library since the author provides no way to edit some of the files programatically.
The way I've done, it is the following:
Unzip folder
File > New > Import Module (select Phoenix-master folder)
Now, my gradle file has:
dependencies { //... compile project(':library') }
But the library doesn't compile. What step am I missing?
I get the following error:
Error:Could not find method isReleaseBuild() for arguments [] on project ':library' of type org.gradle.api.Project.
回答1:
Change these lines:
dependencies {
//...
compile project(':library')
}
into
dependencies {
//...
compile 'com.yalantis:phoenix:1.2.3'
}
回答2:
Please read the usage guidelines already given in the link here Usage . Include the library as local library project.
compile 'com.yalantis:phoenix:1.2.3'
来源:https://stackoverflow.com/questions/41315999/how-can-i-edit-the-source-of-a-gradle-library-and-use-the-changes-in-my-project