Step 1. Add the JitPack repository to your build file
Add it in your root settings.gradle at the end of repositories:
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
maven { url 'https://jitpack.io' }
}
}
Add it in your settings.gradle.kts at the end of repositories:
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
maven { url = uri("https://jitpack.io") }
}
}
Add to pom.xml
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
Add it in your build.sbt at the end of resolvers:
resolvers += "jitpack" at "https://jitpack.io"
Add it in your project.clj at the end of repositories:
:repositories [["jitpack" "https://jitpack.io"]]
Step 2. Add the dependency
dependencies {
implementation 'com.github.raquezha:hookr:1.2.0.2'
}
dependencies {
implementation("com.github.raquezha:hookr:1.2.0.2")
}
<dependency>
<groupId>com.github.raquezha</groupId>
<artifactId>hookr</artifactId>
<version>1.2.0.2</version>
</dependency>
libraryDependencies += "com.github.raquezha" % "hookr" % "1.2.0.2"
:dependencies [[com.github.raquezha/hookr "1.2.0.2"]]
I use this in my applications and I thought I just make it into a library.<br> Simple Utility that hook up your app to this external applications:
This is usually used in Help/Support section where you link your app to external apps.
Step 1. Add the JitPack repository to your build file Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Step 2. Add the dependency
dependencies {
implementation "com.github.raquezha:hookr:1.2.0.2"
}
That's it! In case of a build failed, try cleaning or rebuilding your project. If all else fails try to Invalidate Cache and Restart option
var sampleNumber = "+639123456780"
var facebookId = "1231232131"
Hook.up(context).withSMS(sampleNumber)
Hook.up(context).withPhoneCall(sampleNumber)
Hook.up(context).withMessenger(facebookId)
Can't find your facebook ID? use this: https://findmyfbid.com/
Hook.up(context).withViber(facebookId)
Hook.up(context).withWhatsApp(facebookId)
In case something went wrong you can set a callback,
<br>just call the lambda and it
will be the error message.
Hook.up(context).withSMS(sampleNumber) {
...
Log.e("Hookr", "error: $it")
}