From 37f0b8bae82faf35a0697c7f054f4154a73c5579 Mon Sep 17 00:00:00 2001 From: William Brawner Date: Thu, 22 Feb 2024 22:04:57 -0700 Subject: [PATCH] Remove Plausible --- app/build.gradle.kts | 1 - .../java/com/wbrawner/simplemarkdown/MainActivity.kt | 10 ---------- .../com/wbrawner/simplemarkdown/MarkdownApplication.kt | 9 --------- app/src/main/res/values/strings.xml | 3 --- build.gradle.kts | 3 --- 5 files changed, 26 deletions(-) diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 5ff15fa..a0ce213 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -128,7 +128,6 @@ dependencies { androidTestImplementation("androidx.test.ext:junit:1.1.5") androidTestImplementation("androidx.test.uiautomator:uiautomator:2.2.0") implementation("androidx.core:core-splashscreen:1.0.1") - implementation("com.wbrawner.plausible:plausible-android:0.1.0-SNAPSHOT") implementation("androidx.appcompat:appcompat:1.6.1") implementation("androidx.preference:preference-ktx:1.2.1") implementation("androidx.fragment:fragment-ktx:1.6.1") diff --git a/app/src/main/java/com/wbrawner/simplemarkdown/MainActivity.kt b/app/src/main/java/com/wbrawner/simplemarkdown/MainActivity.kt index 3e4ba3c..f1ea8f6 100644 --- a/app/src/main/java/com/wbrawner/simplemarkdown/MainActivity.kt +++ b/app/src/main/java/com/wbrawner/simplemarkdown/MainActivity.kt @@ -33,7 +33,6 @@ import androidx.core.view.WindowCompat import androidx.navigation.compose.NavHost import androidx.navigation.compose.composable import androidx.navigation.compose.rememberNavController -import com.wbrawner.plausible.android.Plausible import com.wbrawner.simplemarkdown.MarkdownApplication.Companion.fileHelper import com.wbrawner.simplemarkdown.MarkdownApplication.Companion.preferenceHelper import com.wbrawner.simplemarkdown.ui.MainScreen @@ -56,15 +55,6 @@ class MainActivity : AppCompatActivity(), ActivityCompat.OnRequestPermissionsRes installSplashScreen() super.onCreate(savedInstanceState) WindowCompat.setDecorFitsSystemWindows(window, false) - val preferences = mutableMapOf() - preferences["Autosave"] = preferenceHelper[Preference.AUTOSAVE_ENABLED].toString() - val usingCustomCss = !(preferenceHelper[Preference.CUSTOM_CSS] as String?).isNullOrBlank() - preferences["Custom CSS"] = usingCustomCss.toString() - val darkModeSetting = preferenceHelper[Preference.DARK_MODE].toString() - preferences["Dark Mode"] = darkModeSetting - preferences["Error Reports"] = preferenceHelper[Preference.ERROR_REPORTS_ENABLED].toString() - preferences["Readability"] = preferenceHelper[Preference.READABILITY_ENABLED].toString() - Plausible.event("settings", props = preferences, url = "/") setContent { val autosaveEnabled by preferenceHelper.observe(Preference.AUTOSAVE_ENABLED) .collectAsState() diff --git a/app/src/main/java/com/wbrawner/simplemarkdown/MarkdownApplication.kt b/app/src/main/java/com/wbrawner/simplemarkdown/MarkdownApplication.kt index 00af74a..6b0b887 100644 --- a/app/src/main/java/com/wbrawner/simplemarkdown/MarkdownApplication.kt +++ b/app/src/main/java/com/wbrawner/simplemarkdown/MarkdownApplication.kt @@ -2,7 +2,6 @@ package com.wbrawner.simplemarkdown import android.app.Application import android.os.StrictMode -import com.wbrawner.plausible.android.Plausible import com.wbrawner.simplemarkdown.utility.AndroidFileHelper import com.wbrawner.simplemarkdown.utility.AndroidPreferenceHelper import com.wbrawner.simplemarkdown.utility.FileHelper @@ -37,14 +36,6 @@ class MarkdownApplication : Application() { } super.onCreate() ReviewHelper.init(this) - Plausible.enable(!BuildConfig.DEBUG) - Plausible.event( - "build", - url = "/", - props = mapOf( - "Flavor" to BuildConfig.FLAVOR, - "App Version" to BuildConfig.VERSION_NAME - )) fileHelper = AndroidFileHelper(this) preferenceHelper = AndroidPreferenceHelper(this) } diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index af86184..32767f3 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -86,7 +86,4 @@ @string/pref_key_dark_mode_dark @string/pref_key_dark_mode_auto - false - https://plausible.wbrawner.com - simplemarkdown.android.wbrawner.com diff --git a/build.gradle.kts b/build.gradle.kts index 9bbad51..be1bd56 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -17,8 +17,5 @@ allprojects { repositories { google() mavenCentral() - maven { - url = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/") - } } }