build.gradle 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  1. apply plugin: 'com.android.application'
  2. apply plugin: 'io.fabric'// Firebase Crashlytics
  3. // Create a variable called keystorePropertiesFile, and initialize it to your
  4. // keystore.properties file, in the rootProject folder.
  5. def keystorePropertiesFile = rootProject.file("keystore.properties")
  6. // Initialize a new Properties() object called keystoreProperties.
  7. def keystoreProperties = new Properties()
  8. // Load your keystore.properties file into the keystoreProperties object.
  9. keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
  10. def todayDate = new Date().format("yyyyMMdd")
  11. def buildNumber = "01"
  12. def buildStep = "rc8"
  13. android {
  14. compileSdkVersion 27
  15. defaultConfig {
  16. applicationId "kr.co.hanwha.hifive"
  17. minSdkVersion 21
  18. targetSdkVersion 25
  19. versionCode 1
  20. versionName '1.3.3'
  21. testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
  22. multiDexEnabled true
  23. buildConfigField "String", "REVISION", "\"${todayDate}${buildNumber}\""
  24. buildConfigField "String", "RC", "\"${buildStep}\""
  25. buildConfigField "String", "WEB_REAL_URL", "\"https://qtalk.dreamplus.center/newgw/b/v2\""
  26. buildConfigField "String", "WEB_DEV_URL", "\"https://qtalk-dev.dreamplus.center/newgw/b/v2\""
  27. buildConfigField "String", "WEB_LOCAL_URL", "\"http://192.168.0.27:38999/b/v2\""
  28. buildConfigField "String", "REAL_URL", "\"https://qtalk.dreamplus.center/newgw/a/v2\""
  29. buildConfigField "String", "DEV_URL", "\"https://qtalk-dev.dreamplus.center/newgw/a/v2\""
  30. buildConfigField "String", "LOCAL_URL", "\"http://192.168.0.38:38999/a/v2\""
  31. buildConfigField "String", "DOWNLOAD_URL", "\"http://qtalk.dreamplus.center/downloads/\""
  32. }
  33. signingConfigs {
  34. release {
  35. keyAlias keystoreProperties['keyAlias']
  36. keyPassword keystoreProperties['keyPassword']
  37. storeFile file(keystoreProperties['storeFile'])
  38. storePassword keystoreProperties['storePassword']
  39. v1SigningEnabled true
  40. v2SigningEnabled true
  41. }
  42. }
  43. buildTypes {
  44. release {
  45. minifyEnabled false
  46. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  47. signingConfig signingConfigs.release
  48. buildConfigField "String", "SERVER_TYPE", "\"REAL\""
  49. buildConfigField "int", "BUILD_NUMBER", "01"
  50. buildConfigField "String", "HF_KEY_GA_LOG_EVENT", "\"HF_REAL_EVENT\""
  51. }
  52. debug {
  53. minifyEnabled false
  54. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  55. buildConfigField "String", "SERVER_TYPE", "\"DEV\""
  56. buildConfigField "int", "BUILD_NUMBER", "01"
  57. buildConfigField "String", "HF_KEY_GA_LOG_EVENT", "\"HF_EVENT\""
  58. }
  59. }
  60. }
  61. android.applicationVariants.all { variant ->
  62. variant.outputs.all {
  63. def buildName = variant.buildType.name=="debug"?"dev":"prd"
  64. // def buildNumber = variant.buildType.buildConfigFields.get("BUILD_NUMBER").value
  65. outputFileName = "HIFIVE_${buildName}_v.${variant.versionName}_rv_${todayDate}${buildNumber}.apk"
  66. }
  67. }
  68. dependencies {
  69. implementation fileTree(include: ['*.jar'], dir: 'libs')
  70. // implementation 'com.android.support:appcompat-v7:26.1.0'
  71. // implementation 'com.android.support:design:26.1.0'
  72. implementation 'com.android.support:appcompat-v7:27.1.1'
  73. implementation 'com.android.support:design:27.1.1'
  74. implementation 'com.android.support.constraint:constraint-layout:1.0.2'
  75. implementation 'com.google.firebase:firebase-messaging:11.8.0'
  76. implementation 'com.google.firebase:firebase-core:11.8.0'
  77. /**
  78. * Test Unit
  79. */
  80. testImplementation 'junit:junit:4.12'
  81. androidTestImplementation 'com.android.support.test:runner:1.0.1'
  82. androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
  83. // compile 'com.android.support:design:26.1.0'
  84. /**
  85. * Network
  86. */
  87. implementation 'com.squareup.okhttp3:okhttp:3.7.0'
  88. /**
  89. * Json
  90. */
  91. implementation 'com.google.code.gson:gson:2.8.1'
  92. /**
  93. * Support
  94. */
  95. implementation('com.crashlytics.sdk.android:crashlytics:2.7.0-SNAPSHOT@aar') {
  96. // Firebase Crashlytics
  97. transitive = true
  98. }
  99. implementation 'com.github.bumptech.glide:glide:4.7.1'
  100. }
  101. apply plugin: 'com.google.gms.google-services'