No Description

build.gradle 2.0KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. apply plugin: 'com.android.application'
  2. android {
  3. compileSdkVersion rootProject.ext.compileSdkVersion
  4. defaultConfig {
  5. applicationId "io.ionic.starter"
  6. minSdkVersion rootProject.ext.minSdkVersion
  7. targetSdkVersion rootProject.ext.targetSdkVersion
  8. versionCode 1
  9. versionName "1.0"
  10. testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  11. aaptOptions {
  12. // Files and dirs to omit from the packaged assets dir, modified to accommodate modern web apps.
  13. // Default: https://android.googlesource.com/platform/frameworks/base/+/282e181b58cf72b6ca770dc7ca5f91f135444502/tools/aapt/AaptAssets.cpp#61
  14. ignoreAssetsPattern '!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~'
  15. }
  16. }
  17. buildTypes {
  18. release {
  19. minifyEnabled false
  20. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  21. }
  22. }
  23. }
  24. repositories {
  25. flatDir{
  26. dirs '../capacitor-cordova-android-plugins/src/main/libs', 'libs'
  27. }
  28. }
  29. dependencies {
  30. implementation fileTree(include: ['*.jar'], dir: 'libs')
  31. implementation "androidx.appcompat:appcompat:$androidxAppCompatVersion"
  32. implementation "androidx.coordinatorlayout:coordinatorlayout:$androidxCoordinatorLayoutVersion"
  33. implementation "androidx.core:core-splashscreen:$coreSplashScreenVersion"
  34. implementation project(':capacitor-android')
  35. testImplementation "junit:junit:$junitVersion"
  36. androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
  37. androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"
  38. implementation project(':capacitor-cordova-android-plugins')
  39. }
  40. apply from: 'capacitor.build.gradle'
  41. try {
  42. def servicesJSON = file('google-services.json')
  43. if (servicesJSON.text) {
  44. apply plugin: 'com.google.gms.google-services'
  45. }
  46. } catch(Exception e) {
  47. logger.info("google-services.json not found, google-services plugin not applied. Push Notifications won't work")
  48. }