SETUP: update local library linking instructions with composite builds

Reference: https://docs.gradle.org/current/userguide/composite_builds.html

Not only is this the "official" way to do this, but also:
 - It's much simpler (changes only one file)
 - No need for symlinks
 - Android Studio support seems to finally be perfect (understands lombok, knows that there are two Git roots...)

[skip ci][ci skip]

Signed-off-by: Álvaro Brey Vilas <alvaro.brey@nextcloud.com>
This commit is contained in:
Álvaro Brey Vilas 2022-03-22 11:05:35 +01:00
parent ea27e54d26
commit f65b99a265
No known key found for this signature in database
GPG Key ID: 2585783189A62105
1 changed files with 5 additions and 12 deletions

View File

@ -89,22 +89,15 @@ The app is currently equipped to be built with three flavours:
#### 1. Direct usage of library project
This is handy if one wants to make changes both to files app and library:
- In the repository root: `ln -s [path to library clone] nextcloud-android-library`
- Add the following to `settings.gradle`:
```groovy
include ':nextcloud-android-library'
```
- In `app/build.gradle`, replace the following:
```groovy
implementation ("com.github.nextcloud:android-library:$androidLibraryVersion") {
exclude group: 'org.ogce', module: 'xpp3'
includeBuild('[path to library clone]') {
dependencySubstitution {
substitute module('com.github.nextcloud:android-library') using project(':library')
}
}
```
with:
``` groovy
implementation project(':nextcloud-android-library')
```
- Sync project with gradle files
Now every change in library can be directly used in files app.