Remove Plausible

This commit is contained in:
William Brawner 2024-02-22 22:04:57 -07:00
parent ccc4299d10
commit 37f0b8bae8
5 changed files with 0 additions and 26 deletions

View file

@ -128,7 +128,6 @@ dependencies {
androidTestImplementation("androidx.test.ext:junit:1.1.5") androidTestImplementation("androidx.test.ext:junit:1.1.5")
androidTestImplementation("androidx.test.uiautomator:uiautomator:2.2.0") androidTestImplementation("androidx.test.uiautomator:uiautomator:2.2.0")
implementation("androidx.core:core-splashscreen:1.0.1") 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.appcompat:appcompat:1.6.1")
implementation("androidx.preference:preference-ktx:1.2.1") implementation("androidx.preference:preference-ktx:1.2.1")
implementation("androidx.fragment:fragment-ktx:1.6.1") implementation("androidx.fragment:fragment-ktx:1.6.1")

View file

@ -33,7 +33,6 @@ import androidx.core.view.WindowCompat
import androidx.navigation.compose.NavHost import androidx.navigation.compose.NavHost
import androidx.navigation.compose.composable import androidx.navigation.compose.composable
import androidx.navigation.compose.rememberNavController import androidx.navigation.compose.rememberNavController
import com.wbrawner.plausible.android.Plausible
import com.wbrawner.simplemarkdown.MarkdownApplication.Companion.fileHelper import com.wbrawner.simplemarkdown.MarkdownApplication.Companion.fileHelper
import com.wbrawner.simplemarkdown.MarkdownApplication.Companion.preferenceHelper import com.wbrawner.simplemarkdown.MarkdownApplication.Companion.preferenceHelper
import com.wbrawner.simplemarkdown.ui.MainScreen import com.wbrawner.simplemarkdown.ui.MainScreen
@ -56,15 +55,6 @@ class MainActivity : AppCompatActivity(), ActivityCompat.OnRequestPermissionsRes
installSplashScreen() installSplashScreen()
super.onCreate(savedInstanceState) super.onCreate(savedInstanceState)
WindowCompat.setDecorFitsSystemWindows(window, false) WindowCompat.setDecorFitsSystemWindows(window, false)
val preferences = mutableMapOf<String, String>()
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 { setContent {
val autosaveEnabled by preferenceHelper.observe<Boolean>(Preference.AUTOSAVE_ENABLED) val autosaveEnabled by preferenceHelper.observe<Boolean>(Preference.AUTOSAVE_ENABLED)
.collectAsState() .collectAsState()

View file

@ -2,7 +2,6 @@ package com.wbrawner.simplemarkdown
import android.app.Application import android.app.Application
import android.os.StrictMode import android.os.StrictMode
import com.wbrawner.plausible.android.Plausible
import com.wbrawner.simplemarkdown.utility.AndroidFileHelper import com.wbrawner.simplemarkdown.utility.AndroidFileHelper
import com.wbrawner.simplemarkdown.utility.AndroidPreferenceHelper import com.wbrawner.simplemarkdown.utility.AndroidPreferenceHelper
import com.wbrawner.simplemarkdown.utility.FileHelper import com.wbrawner.simplemarkdown.utility.FileHelper
@ -37,14 +36,6 @@ class MarkdownApplication : Application() {
} }
super.onCreate() super.onCreate()
ReviewHelper.init(this) 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) fileHelper = AndroidFileHelper(this)
preferenceHelper = AndroidPreferenceHelper(this) preferenceHelper = AndroidPreferenceHelper(this)
} }

View file

@ -86,7 +86,4 @@
<item>@string/pref_key_dark_mode_dark</item> <item>@string/pref_key_dark_mode_dark</item>
<item>@string/pref_key_dark_mode_auto</item> <item>@string/pref_key_dark_mode_auto</item>
</string-array> </string-array>
<string name="plausible_enable_startup">false</string>
<string name="plausible_host">https://plausible.wbrawner.com</string>
<string name="plausible_domain">simplemarkdown.android.wbrawner.com</string>
</resources> </resources>

View file

@ -17,8 +17,5 @@ allprojects {
repositories { repositories {
google() google()
mavenCentral() mavenCentral()
maven {
url = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
}
} }
} }