From b7d10122ba9bde08208f5de70ffd49aa5452eb71 Mon Sep 17 00:00:00 2001 From: str4d Date: Fri, 15 Aug 2014 01:49:45 +0000 Subject: [PATCH] Make it easier to use a local copy/build of the client library --- README.md | 6 ++++++ build.gradle | 15 +++++++++++---- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 4610227..fa17008 100644 --- a/README.md +++ b/README.md @@ -46,6 +46,12 @@ Gradle will pull dependencies over the clearnet by default. To use Tor, create a botesrc=/path/to/i2p.i2p-bote ``` +5. If you want to use a local copy of the I2P Android client library, place it in a folder and add the following line to your `~/.gradle/gradle.properties`: + + ``` + localFileRepoDir=/path/to/folder + ``` + ### Building from the command line 1. Create a `local.properties` file in `i2p.i2p-bote.android` containing: diff --git a/build.gradle b/build.gradle index 660c6e4..a036c2c 100644 --- a/build.gradle +++ b/build.gradle @@ -8,11 +8,18 @@ buildscript { } } +if (hasProperty('localFileRepoDir')) { + allprojects { + repositories { + flatDir { + dirs file(localFileRepoDir) + } + } + } +} + allprojects { repositories { -// flatDir { -// dirs file("${project.rootDir}/aars") -// } mavenCentral() } -} \ No newline at end of file +}