Guest User

Untitled

a guest
Apr 24th, 2018
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.22 KB | None | 0 0
  1. desc "Clean, build development release"
  2. lane :dev do |options|
  3. if options[:clean]
  4. clean_android
  5. end
  6. rntest
  7. test
  8. gradle(
  9. task: "assemble",
  10. build_type: "debug",
  11. project_dir: "./")
  12. end
  13.  
  14. apply plugin: "com.android.application"
  15.  
  16. apply plugin: 'io.fabric'
  17.  
  18. repositories {
  19. maven { url 'https://maven.fabric.io/public' }
  20. }
  21.  
  22.  
  23. import com.android.build.OutputFile
  24.  
  25. project.ext.react = [
  26. entryFile: "index.js",
  27. bundleInRelease: true,
  28. bundleInDebug: false,
  29. bundleInStaging: true,
  30. ]
  31.  
  32.  
  33.  
  34. apply from: "../../node_modules/react-native/react.gradle"
  35.  
  36.  
  37. def enableSeparateBuildPerCPUArchitecture = false
  38.  
  39. /**
  40. * Run Proguard to shrink the Java bytecode in release builds.
  41. */
  42. def enableProguardInReleaseBuilds = false
  43.  
  44. android {
  45. compileSdkVersion 25
  46. buildToolsVersion "25.0.1"
  47.  
  48. defaultConfig {
  49. applicationId "be.appfoundry.digitalreceptionist"
  50. minSdkVersion 16
  51. targetSdkVersion 22
  52. versionCode 1
  53. def env = System.getenv()
  54. versionName "1.0.0." + env['BUILD_NUMBER']
  55. ndk {
  56. abiFilters "armeabi-v7a", "x86"
  57. }
  58. }
  59. signingConfigs {
  60. release {
  61. storeFile file(MYAPP_RELEASE_STORE_FILE)
  62. storePassword "afst18gv"
  63. keyAlias MYAPP_RELEASE_KEY_ALIAS
  64. keyPassword "afst18gv"
  65. }
  66. }
  67. splits {
  68. abi {
  69. reset()
  70. enable enableSeparateBuildPerCPUArchitecture
  71. universalApk false // If true, also generate a universal APK
  72. include "armeabi-v7a", "x86"
  73. }
  74. }
  75. buildTypes {
  76. staging {
  77. minifyEnabled enableProguardInReleaseBuilds
  78. proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
  79. applicationIdSuffix ".staging"
  80. signingConfig signingConfigs.release
  81. }
  82. release {
  83. minifyEnabled enableProguardInReleaseBuilds
  84. proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
  85. signingConfig signingConfigs.release
  86. }
  87. debug {
  88. applicationIdSuffix ".debug"
  89. }
  90. }
  91. dexOptions {
  92. jumboMode true
  93. }
  94. // applicationVariants are e.g. debug, release
  95. applicationVariants.all { variant ->
  96. variant.outputs.each { output ->
  97. // For each separate APK per architecture, set a unique version code as described here:
  98. // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
  99. def versionCodes = ["armeabi-v7a":1, "x86":2]
  100. def abi = output.getFilter(OutputFile.ABI)
  101. if (abi != null) { // null for the universal-debug, universal-release variants
  102. output.versionCodeOverride =
  103. versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
  104. }
  105. }
  106. }
  107. }
  108.  
  109.  
  110. dependencies {
  111. compile project(':react-native-splash-screen')
  112. compile(project(':react-native-firebase')) {
  113. transitive = false
  114. }
  115. compile project(':react-native-push-notification')
  116. compile fileTree(include: ['*.jar'], dir: 'libs')
  117. compile 'com.android.support:appcompat-v7:23.0.1'
  118. compile 'com.facebook.react:react-native:+'
  119. compile project(':react-native-maps')
  120. compile project(':react-native-navigation')
  121. // From node_modules
  122. compile('com.crashlytics.sdk.android:crashlytics:2.9.1@aar') {
  123. transitive = true
  124. }
  125. compile(project(':react-native-maps')){
  126. exclude group: 'com.google.android.gms', module: 'play-services-base'
  127. exclude group: 'com.google.android.gms', module: 'play-services-maps'
  128. }
  129. // Firebase dependencies
  130. compile "com.google.android.gms:play-services-base:11.8.0"
  131. compile "com.google.firebase:firebase-core:11.8.0"
  132. compile "com.google.firebase:firebase-auth:11.8.0"
  133. compile "com.google.firebase:firebase-firestore:11.8.0"
  134.  
  135. compile "com.google.android.gms:play-services-maps:11.8.0"
  136.  
  137. }
  138.  
  139. // Run this once to be able to run the application with BUCK
  140. // puts all compile dependencies into folder libs for BUCK to use
  141. task copyDownloadableDepsToLibs(type: Copy) {
  142. from configurations.compile
  143. into 'libs'
  144. }
  145.  
  146.  
  147. apply plugin: 'com.google.gms.google-services'
Add Comment
Please, Sign In to add comment