Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .mega-linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,6 @@ FILEIO_REPORTER: false
# DISABLE_ERRORS: true
MARKDOWN_MARKDOWNLINT_CONFIG_FILE: .markdownlint.json
MARKDOWN_MARKDOWNLINT_DISABLE_ERRORS: false
KOTLIN_DETEKT_ARGUMENTS: -c config/detekt/detekt.yml -ex "**/build/**" -p "lib/detekt-formatting-1.23.7.jar"
KOTLIN_DETEKT_ARGUMENTS: -c config/detekt/detekt.yml -ex "**/build/**"

DISABLE_ERRORS: true
2 changes: 1 addition & 1 deletion build-logic/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ dependencies {
implementation(libs.serialization)
implementation(libs.com.google.devtools.ksp.gradle.plugin)
implementation(libs.popcorn.guineapig)
}
}
9 changes: 5 additions & 4 deletions build-logic/src/main/java/Config.kt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
@file:Suppress("MaxLineLength")
import org.gradle.api.JavaVersion
import org.jetbrains.kotlin.gradle.dsl.JvmTarget

Expand All @@ -9,7 +10,7 @@ object Config {
const val compileSdkVersion = 36
const val minSdkVersion = 28
const val targetSdkVersion = 36
const val versionName = "1.3"
const val versionName = "1.4"
const val versionCode = 1
const val testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"

Expand All @@ -23,9 +24,9 @@ object Config {
private const val tmdb_token_name_release = "TMDB_BEARER_TOKEN_RELEASE"

private const val bearear_without_environment = "eyJhbGciOiJIUzI1NiJ9.eyJhdWQiOiJiNDg2NWM4YTAzNzhmM2I4NjI0OWU1ZjNiYWFiMjU2NyIsInN1YiI6IjY0Mjk4YTg5YTNlNGJhMWM0NDgzM2U4OCIsInNjb3BlcyI6WyJhcGlfcmVhZCJdLCJ2ZXJzaW9uIjoxfQ.9cIxv29vkaZ2yW88DIFRUFK_nXbK2b6KS8t96kA8WAE"

val api_bearer = System.getenv(tmdb_token_name_debug) ?: bearear_without_environment
val api_bearer_debug = System.getenv(tmdb_token_name_debug) ?: bearear_without_environment
val api_bearer_release = System.getenv(tmdb_token_name_release) ?: bearear_without_environment
val api_bearer_release =
System.getenv(tmdb_token_name_release) ?: bearear_without_environment
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ detekt {
"src/test/kotlin"
)

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

allprojects {
apply(plugin = "org.jetbrains.dokka")
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -50,4 +50,4 @@ afterEvaluate {

ksp {
arg("KOIN_CONFIG_CHECK", "true")
}
}
2 changes: 1 addition & 1 deletion build-logic/src/main/java/extensions/CommonExtensions.kt
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,4 @@ internal val Project.libs: VersionCatalog
get() {
return project.extensions.getByType<VersionCatalogsExtension>()
.named("libs")
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@ package extensions
import org.gradle.api.artifacts.Dependency
import org.gradle.api.artifacts.dsl.DependencyHandler

@Suppress("FunctionNaming")
fun DependencyHandler.`dokkaPlugin`(dependencyNotation: Any): Dependency? =
add("dokkaPlugin", dependencyNotation)
add("dokkaPlugin", dependencyNotation)
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@ popcornGuineapigParentConfig {
),
),
)
}
}
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ allprojects {
url = URI.create("https://jitpack.io")
}
}
}
}
2 changes: 1 addition & 1 deletion composeApp/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -44,4 +44,4 @@ kotlin {
implementation(libs.kotzilla.sdk.compose)
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ class CustomApplication : Application() {
)
)
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,9 @@ object AppModule {
private val module = module {
single(QualifierDispatcherIO) { Dispatchers.IO }
}
val list = module + NetworkModule().module + LocalStorageModule.module + SyncModule.module + ListStreamModule.module
}
val list = module +
NetworkModule().module +
LocalStorageModule.module +
SyncModule.module +
ListStreamModule.module
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ expect fun LottieComponent(
jsonString: String,
modifier: Modifier = Modifier,
onAnimationFinished: () -> Unit
)
)
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ fun NavGraphBuilder.splashNavGraph(navController: NavHostController) {
}
)
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package com.codandotv.streamplayerapp

import androidx.compose.ui.window.ComposeUIViewController

@Suppress("FunctionNaming")
fun MainViewController() = ComposeUIViewController {
StreamPlayerApp()
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ class KoinIosHelper {
)
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ actual fun LottieComponent(
view
}
)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ import platform.UIKit.UIView

interface LottieViewProvider {
fun provideLottieView(lottieAnimationJson: String, onAnimationFinish : () -> Unit) : UIView
}
}
50 changes: 6 additions & 44 deletions config/detekt/detekt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ exceptions:
ObjectExtendsThrowable:
active: false
PrintStackTrace:
active: false
active: true
RethrowCaughtException:
active: true
ReturnFromFinally:
Expand Down Expand Up @@ -402,11 +402,6 @@ naming:
ClassNaming:
active: true
classPattern: "[A-Z][a-zA-Z0-9]*"
ConstructorParameterNaming:
active: true
parameterPattern: "[a-z][A-Za-z0-9]*"
privateParameterPattern: "[a-z][A-Za-z0-9]*"
excludeClassPattern: "$^"
EnumNaming:
active: true
enumEntryPattern: "[A-Z][_a-zA-Z0-9]*"
Expand Down Expand Up @@ -440,15 +435,10 @@ naming:
parameterPattern: "[a-z][A-Za-z0-9]*"
excludeClassPattern: "$^"
InvalidPackageDeclaration:
active: true
rootPackage: ""
requireRootInDeclaration: false
active: false
LambdaParameterNaming:
active: false
parameterPattern: "[a-z][A-Za-z0-9]*|_"
MatchingDeclarationName:
active: true
mustBeFirst: true
MemberNameEqualsClassName:
active: true
ignoreOverridden: true
Expand All @@ -463,7 +453,6 @@ naming:
privatePropertyPattern: "(_)?[A-Za-z][_A-Za-z0-9]*"
PackageNaming:
active: false
packagePattern: '[a-z]+(\.[a-z][A-Za-z0-9]*)*'
TopLevelPropertyNaming:
active: true
constantPattern: "[A-Z][_A-Z0-9]*"
Expand Down Expand Up @@ -741,42 +730,15 @@ style:
ignoreOverridden: false
ignoreUsageInGenerics: false
FunctionOnlyReturningConstant:
active: false
active: true
ignoreOverridableFunction: true
ignoreActualFunction: true
excludedFunctions: []
LoopWithTooManyJumpStatements:
active: true
maxJumpCount: 1
MagicNumber:
active: true
excludes:
[
"**/test/**",
"**/androidTest/**",
"**/commonTest/**",
"**/jvmTest/**",
"**/androidUnitTest/**",
"**/androidInstrumentedTest/**",
"**/jsTest/**",
"**/iosTest/**",
"**/*.kts",
]
ignoreNumbers:
- "-1"
- "0"
- "1"
- "2"
ignoreHashCodeFunction: true
ignorePropertyDeclaration: false
ignoreLocalVariableDeclaration: false
ignoreConstantDeclaration: true
ignoreCompanionObjectPropertyDeclaration: true
ignoreAnnotation: false
ignoreNamedArgument: true
ignoreEnums: false
ignoreRanges: false
ignoreExtensionFunctions: true
active: false
MandatoryBracesLoops:
active: false
MaxChainedCallsOnSameLine:
Expand Down Expand Up @@ -804,7 +766,7 @@ style:
NestedClassesVisibility:
active: true
NewLineAtEndOfFile:
active: false
active: true
NoTabs:
active: false
NullableBooleanCheck:
Expand Down Expand Up @@ -934,4 +896,4 @@ style:
WildcardImport:
active: true
excludeImports:
- "java.util.*"
- "java.util.*"
2 changes: 1 addition & 1 deletion core-background-work/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ kotlin {
api(libs.kmpnotifier)
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,9 @@ class SyncWorker(
private val syncManager: SyncManager by inject()

override suspend fun doWork(): Result {
return try {
return runCatching {
syncManager.syncData()
Result.success()
} catch (e: Exception) {
println("Erro no SyncWorker ${e.message}")
Result.retry()
}
}.getOrDefault(Result.retry())
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ object NotifierHelper {
image = NotificationImage.Url(imageUrl)
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ class SyncManager(
delay(2000)
println("SyncManager: Sincronização concluída!")
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ object SyncModule {
val module = module(createdAtStart = true) {
single { SyncManager(get()) }
}
}
}
2 changes: 1 addition & 1 deletion core-camera-gallery/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ kotlin {
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ actual class SharedImage(private val bitmap: Bitmap?) {
actual fun toImageBitmap(): ImageBitmap? {
return bitmap?.asImageBitmap()
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,4 @@ actual class CameraManager actual constructor(
actual fun launch() {
onLaunch()
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@ class ComposeFileProvider : FileProvider(
)
}.getOrNull()
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,4 @@ actual class GalleryManager actual constructor(private val onLaunch: () -> Unit)
actual fun launch() {
onLaunch()
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ import androidx.compose.ui.graphics.ImageBitmap
expect class SharedImage {
fun toByteArray(): ByteArray?
fun toImageBitmap(): ImageBitmap?
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ expect class CameraManager(
onLaunch: () -> Unit
) {
fun launch()
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ actual class SharedImage(private val image: UIImage?) {
private companion object {
const val COMPRESSION_QUALITY = 0.99
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ actual fun rememberCameraManager(onResult: (SharedImage?) -> Unit): CameraManage
CameraManager {
imagePicker.setSourceType(UIImagePickerControllerSourceType.UIImagePickerControllerSourceTypeCamera)
imagePicker.setAllowsEditing(true)
imagePicker.setCameraCaptureMode(UIImagePickerControllerCameraCaptureMode.UIImagePickerControllerCameraCaptureModePhoto)
imagePicker.setCameraCaptureMode(
UIImagePickerControllerCameraCaptureMode.UIImagePickerControllerCameraCaptureModePhoto
)
imagePicker.setDelegate(cameraDelegate)
UIApplication.sharedApplication.keyWindow?.rootViewController?.presentViewController(
imagePicker, true, null
Expand All @@ -52,4 +54,4 @@ actual class CameraManager actual constructor(
actual fun launch() {
onLaunch()
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,4 @@ actual class GalleryManager actual constructor(private val onLaunch: () -> Unit)
actual fun launch() {
onLaunch()
}
}
}
Loading
Loading