Skip to content

Commit

Permalink
Build changes (#303)
Browse files Browse the repository at this point in the history
* Bump TouchImageView to 3.2.0

* Update targetSdk, define buildToolsVersion

* Set jvmTarget to 11

* Add verification of the downloaded Gradle distribution via SHA-256 hash sum comparison

* Migrate build system to Kotlin DSL

* Bump Matomo SDK
  • Loading branch information
PatrykMis authored Jun 7, 2022
1 parent 2a619e1 commit ed44af3
Show file tree
Hide file tree
Showing 7 changed files with 105 additions and 105 deletions.
70 changes: 0 additions & 70 deletions app/build.gradle

This file was deleted.

70 changes: 70 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
plugins {
id("com.android.application")
kotlin("android")
}

android {
compileSdk = 32
buildToolsVersion = "32.0.0"
compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}
kotlinOptions {
jvmTarget = JavaVersion.VERSION_11.toString()
}
defaultConfig {
applicationId = "com.todobom.opennotescanner"
minSdk = 21
targetSdk = 31
versionCode = 36
versionName = "1.0.36"
}
buildTypes {
getByName("release") {
isMinifyEnabled = false
proguardFiles(getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro")
}
}
flavorDimensions += "version"
productFlavors {
create("fdroid") {
dimension = "version"
applicationIdSuffix = ""
versionNameSuffix = "-fdroid"
}
create("gplay") {
dimension = "version"
applicationIdSuffix = ""
versionNameSuffix = "-gplay"
}
}
lint {
abortOnError = false
}
}

dependencies {
implementation(fileTree(mapOf("include" to listOf("*.jar"), "dir" to "libs")))

implementation("androidx.core:core-ktx:1.8.0")
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.6.21")

implementation("androidx.exifinterface:exifinterface:1.3.3")
testImplementation("junit:junit:4.13.2")
implementation("androidx.appcompat:appcompat:1.4.2")
implementation("com.google.android.material:material:1.6.1")
implementation("com.google.zxing:core:3.5.0")
implementation("com.github.ctodobom:OpenCV-3.1.0-Android:9e00ee4218ca0c9e60a905c9f09bf499f9dc5115")
implementation("us.feras.mdv:markdownview:1.1.0")
implementation("com.github.ctodobom:drag-select-recyclerview:0.3.4.ctodobom.sections")
implementation("com.github.nostra13:Android-Universal-Image-Loader:v1.9.5")
implementation("com.github.ctodobom:FabToolbar:3c5f0e0ff1b6d5089e20b7da7157a604075ae943")
implementation("com.github.matomo-org:matomo-sdk-android:4.1.4")
implementation("com.github.MikeOrtiz:TouchImageView:3.2.0")

val itextpdf_version = "7.2.2"
implementation("com.itextpdf:kernel:$itextpdf_version")
implementation("com.itextpdf:layout:$itextpdf_version")
implementation("com.itextpdf:io:$itextpdf_version")
}
32 changes: 0 additions & 32 deletions build.gradle

This file was deleted.

22 changes: 22 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
repositories {
mavenCentral()
jcenter()
google()
maven(url = "https://jitpack.io")
}

dependencies {
classpath("com.android.tools.build:gradle:7.2.1")
classpath(kotlin("gradle-plugin", version = "1.6.21"))

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}

tasks.register("clean", Delete::class) {
delete(rootProject.buildDir)
}
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Sat Jun 04 09:50:44 BRT 2022
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=e6d864e3b5bc05cc62041842b306383fc1fefcec359e70cebb1d470a6094ca82
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-all.zip
1 change: 0 additions & 1 deletion settings.gradle

This file was deleted.

11 changes: 11 additions & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
jcenter()
google()
maven(url = "https://jitpack.io")
}
}
rootProject.name = "Open Note Scanner"
include(":app")

0 comments on commit ed44af3

Please sign in to comment.