build.gradle 4.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. apply plugin: 'com.android.application'
  2. apply plugin: 'kotlin-android'
  3. apply plugin: 'kotlin-android-extensions'
  4. apply plugin: 'kotlin-kapt'
  5. configurations.all {
  6. resolutionStrategy.eachDependency { DependencyResolveDetails details ->
  7. def requested = details.requested
  8. if (requested.group == "androidx") {
  9. if (!requested.name.startsWith("multidex")) {
  10. details.useVersion "${targetSdk}.+"
  11. }
  12. }
  13. }
  14. }
  15. android {
  16. compileSdkVersion 32
  17. compileOptions {
  18. sourceCompatibility JavaVersion.VERSION_11
  19. targetCompatibility JavaVersion.VERSION_11
  20. }
  21. kotlinOptions {
  22. jvmTarget = "11"
  23. }
  24. defaultConfig {
  25. applicationId "fr.riff_app.riff"
  26. minSdkVersion 16
  27. targetSdkVersion 32
  28. multiDexEnabled true
  29. versionCode 121
  30. versionName "1.2.1"
  31. testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  32. vectorDrawables.useSupportLibrary = true
  33. }
  34. // Note: I noticed that enabling these make the release app crash on API19-.
  35. // So I'll disable it as of now for maximum compatibility, even if the app size is a tad bigger.
  36. /*
  37. buildTypes {
  38. release {
  39. minifyEnabled true
  40. shrinkResources true
  41. proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
  42. }
  43. }
  44. */
  45. }
  46. dependencies {
  47. def multidex_version = "2.0.1"
  48. implementation "androidx.multidex:multidex:$multidex_version"
  49. implementation fileTree(dir: 'libs', include: ['*.jar'])
  50. /*
  51. implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
  52. implementation 'androidx.appcompat:appcompat:1.1.0'
  53. implementation 'androidx.core:core-ktx:1.1.0'
  54. implementation 'com.google.android.material:material:1.0.0'
  55. implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
  56. implementation 'androidx.navigation:navigation-fragment-ktx:2.1.0'
  57. implementation 'androidx.navigation:navigation-ui-ktx:2.1.0'
  58. implementation 'androidx.vectordrawable:vectordrawable:1.1.0'
  59. implementation 'androidx.lifecycle:lifecycle-extensions:2.1.0'
  60. implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.1.0'
  61. testImplementation 'junit:junit:4.12'
  62. androidTestImplementation 'androidx.test.ext:junit:1.1.1'
  63. androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
  64. */
  65. implementation "androidx.media:media:1.5.0"
  66. //noinspection GradleDependency
  67. implementation 'com.google.android.exoplayer:exoplayer:2.11.3'
  68. //implementation project(':exoplayer-library') // uses local ExoPlayer clone, from dev-v2 branch (fixes ISO-8859-1 ICY metadata
  69. implementation 'androidx.lifecycle:lifecycle-extensions:2.2.0'
  70. implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.4.1'
  71. implementation 'androidx.recyclerview:recyclerview:1.2.1'
  72. implementation 'androidx.preference:preference-ktx:1.2.0'
  73. // jsoup HTML parser library @ https://jsoup.org/
  74. // implementation 'org.jsoup:jsoup:1.12.1'
  75. // RSS parser library @ https://github.com/prof18/RSS-Parser
  76. implementation 'com.prof.rssparser:rssparser:2.0.4'
  77. // new implems
  78. implementation deps.kotlin.stdlib
  79. implementation deps.support.app_compat
  80. implementation deps.support.design
  81. implementation deps.support.core_ktx
  82. implementation deps.constraint_layout
  83. implementation deps.arch_core.runtime
  84. // Navigation
  85. implementation deps.navigation.runtime_ktx
  86. implementation deps.navigation.fragment_ktx
  87. implementation deps.navigation.ui_ktx
  88. // Android Testing Support Library's runner and rules
  89. /*
  90. androidTestImplementation deps.atsl.runner
  91. androidTestImplementation deps.atsl.rules
  92. androidTestImplementation deps.room.testing
  93. androidTestImplementation deps.arch_core.testing
  94. */
  95. // Espresso UI Testing
  96. androidTestImplementation deps.espresso.core
  97. androidTestImplementation deps.espresso.contrib
  98. androidTestImplementation deps.espresso.intents
  99. }