Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
pklawikowski-schibsted authored Nov 6, 2023
1 parent 068e996 commit 7e539ad
Showing 1 changed file with 3 additions and 30 deletions.
33 changes: 3 additions & 30 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ You can find Javadoc at [https://pages.github.schibsted.io/spt-dataanalytics/eve
<!-- Table of contents generated generated by http://tableofcontent.eu -->
- [Getting Started](#getting-started)
- [Understand the Purpose of `event-formats`](#understand-the-purpose-of-event-formats)
- [Setup Schibsted Repository](#setup-schibsted-repository)
- [Setup Repository](#setup-repository)
- [Add `event-sdk-android` Library](#add-event-sdk-android-library)
- [Google Play Services](#google-play-services)
- [Other Dependencies](#other-dependencies)
Expand Down Expand Up @@ -98,38 +98,11 @@ Since version 7, you can use this SDK without a dependency on `event-formats-jvm
This SDK is designed to work in multithreaded environment. Internally it uses 2 threads.


### Setup Schibsted Repository
The SDK is released on Schibsted artifactory and Sonatype.

To use Schibsted artifactory, you need to include
this repository with its credentials (you might already have it):
```kotlin
val artifactoryContext = properties["artifactory_context"]?.toString() ?: System.getenv("ARTIFACTORY_CONTEXT")
maven {
url = uri("$artifactoryContext/libs-release")
credentials {
username = properties["artifactory_user"]?.toString() ?: System.getenv("ARTIFACTORY_USER")
password = properties["artifactory_pwd"]?.toString() ?: System.getenv("ARTIFACTORY_PWD")
}
}
```
You can either set the credentials as environment variables:
```
export [email protected]
export ARTIFACTORY_PWD=<artifactory-password>
export ARTIFACTORY_CONTEXT=https://artifacts.schibsted.io/artifactory
```
Or as gradle properties, suggested at `~/.gradle/gradle.properties`:
```
[email protected]
artifactory_pwd=<artifactory-password>
artifactory_context=https://artifacts.schibsted.io/artifactory
```

### Setup Repository
Sonatype artifact is available from `mavenCentral()` repository.

### Add `event-sdk-android` Library
Once Schibsted artifactory is set up, add the following line to your `build.gradle`:
Once repository is set up, add the following line to your `build.gradle`:
```kotlin
implementation("com.schibsted.spt.tracking:event-sdk-android:<version>")
```
Expand Down

0 comments on commit 7e539ad

Please sign in to comment.