Skip to content

Commit

Permalink
readme codeblocks fix
Browse files Browse the repository at this point in the history
  • Loading branch information
amarose committed Aug 12, 2024
1 parent 7addaa1 commit 67ad878
Showing 1 changed file with 34 additions and 26 deletions.
60 changes: 34 additions & 26 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,20 +64,20 @@ plugins {
alias(libs.plugins.google.gms.google.services)
}

dependencies {
// GMS
dependencies {
// GMS
implementation(platform(libs.firebase.bom))
implementation(libs.firebase.messaging)
// HMS
implementation(libs.agconnect.core)
implementation(libs.hms.push)
implementation(libs.firebase.messaging)
// HMS
implementation(libs.agconnect.core)
implementation(libs.hms.push)
}



// /build.gradle.kts
plugins {
alias(libs.plugins.google.gms.google.services) apply false
alias(libs.plugins.google.gms.google.services) apply false
}
```
4. **Provide GMS / HMS credentials in PushPushGo application (/project/providers)**
Expand Down Expand Up @@ -109,14 +109,16 @@ plugins {

Groovy DSL
```groovy
// /build.gradle
allprojects {
repositories {
// local repo
mavenLocal()
// or
// jitpack
maven { url 'https://jitpack.io' } }}
// /build.gradle
allprojects {
repositories {
// local repo
mavenLocal()
// or
// jitpack
maven { url 'https://jitpack.io' }
}
}
// /app/build.gradle
Expand All @@ -132,10 +134,10 @@ Kotlin DSL
```kotlin
// /settings.gradle.kts
dependencyResolutionManagement {
repositories {
google()
mavenCentral()
maven ( "https://jitpack.io" )
repositories {
google()
mavenCentral()
maven ( "https://jitpack.io" )
}
}

Expand All @@ -152,7 +154,7 @@ ppg-sdk = { module = "com.github.ppgco.android-sdk:sdk", version.ref = "ppgSdk"

// /app/build.gradle.kts
dependencies {
implementation(libs.ppg.sdk)
implementation(libs.ppg.sdk)
}

```
Expand All @@ -177,16 +179,16 @@ In your main activity tag:
```
```xml
<intent-filter>
<action android:name="APP_PUSH_CLICK" />
<category android:name="android.intent.category.DEFAULT" />
<action android:name="APP_PUSH_CLICK" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
```
3. **Add to your MainActivity**:

in onCreate():
```java
if (savedInstanceState == null) {
PushPushGo.getInstance().handleBackgroundNotificationClick(intent);
PushPushGo.getInstance().handleBackgroundNotificationClick(intent);
}
```
in onNewIntent():
Expand Down Expand Up @@ -233,14 +235,20 @@ PushPushGo.getInstance().createBeacon()
## Publishing

To maven local repository:
```sh $ ./gradlew :library:publishToMavenLocal```
```sh
$ ./gradlew :library:publishToMavenLocal
```

## Tests
Run tests in `library` module:
```sh $ ./gradlew :library:testDebug```
```sh
$ ./gradlew :library:testDebug
```

Generate coverage report:
```sh $ ./gradlew :library:jacocoTestReport```
```sh
$ ./gradlew :library:jacocoTestReport
```

HTML coverage report path:
`library/build/reports/jacocoTestReport/html/`

0 comments on commit 67ad878

Please sign in to comment.