Commit fd6d5184 authored by Lucas Legrand's avatar Lucas Legrand

README completed. TODO: Check README presentation in the Gitlab page, edit...

README completed. TODO: Check README presentation in the Gitlab page, edit build.gradle (app one) to allow conditional dependency and remove the separate project (production/import) need.
parent 298cc2ce
......@@ -77,57 +77,49 @@ Warning: If a not working version is produced, before building it again, clear t
Sending files to our remote repository
Go to your local maven_repository and type:
Go to your local maven_repository and in a terminal type:
git add org
git commit -m 'Your message'
git push
EXPLOITATION
In this second project, we remove all previous dependency to liblinphone-sdk subproject,
from linphone-android build.gradle file, settings.gradle and can delete liblinphone-sdk folder.
Additions must be made in build.gradle:
-In allprojects/repositories:
maven{
url "https://gitlab.linphone.org/BC/public/maven_repository/raw/releases"
}
Keep the raw part even with future libraries, it shows the way to the real files, not thoses displayed in the web browser. The releases part is the branch.
-In dependencies:
Replace implementation project(':liblinphone-sdk')
With implementation 'org.linphone.maven:liblinphone-sdk:4.0.0'
As you can see, we reuse the settings provided in the PRODUCTION part in order to give the way to gradle to find the right dependency.
You can now build linphone-android as the dependency is provided remotely.
How to use hosted Liblinphone SDK as a remote dependency
FEATURES THAT CAN BE INCLUDED:
-Send .aar and Maven files to this repository through Git in Android Studio
In another linphone-android project, edit linphone-android build.gradle as in the one located in maven_repository root.
-Create controllers about version exclusivity
Set our Maven repository source:
SOURCES:
allprojects {
repositories {
maven{
url "https://gitlab.linphone.org/BC/public/maven_repository/raw/master"
}
}
}
Change our local project dependency to remote dependency:
All of theses served me to understand the way to produce this repository:
http://downright-amazed.blogspot.com/2011/09/hosting-maven-repository-on-github-for.html (STEP3 for the real artifact URL issue)
dependencies {
// implementation project(':liblinphone-sdk')
releaseImplementation 'org.linphone.maven:liblinphone-sdk:4.0.0-RELEASE'
debugImplementation 'org.linphone.maven:liblinphone-sdk:4.0.0'
}
https://docs.gradle.org/current/userguide/maven_plugin.html
Comment release or debug line if no remote library is available for it.
Use again the settings provided in the creation part in order to give the way to gradle to find the right dependency:
https://jeroenmols.com/blog/2016/02/05/wagongit/
'groupId:artifactId:version'
http://kodbiro.com/use-github-pages-as-your-own-maven-repository/
In case of another library need, provided it is hosted, just change artifactId and version in accordance to its declaration in the creation part.
......@@ -35,7 +35,6 @@ allprojects {
maven{
url "https://gitlab.linphone.org/BC/public/maven_repository/raw/master"
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment