Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

4 лет назад
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. // Top-level build file where you can add configuration options common to all sub-projects/modules.
  2. import groovy.json.JsonSlurper
  3. buildscript {
  4. repositories {
  5. google()
  6. jcenter()
  7. }
  8. dependencies {
  9. classpath("com.android.tools.build:gradle:3.6.3")
  10. // NOTE: Do not place your application dependencies here; they belong
  11. // in the individual module build.gradle files
  12. }
  13. }
  14. allprojects {
  15. repositories {
  16. mavenLocal()
  17. maven {
  18. // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
  19. url("$rootDir/../node_modules/react-native/android")
  20. }
  21. maven {
  22. // Android JSC is installed from npm
  23. url("$rootDir/../node_modules/jsc-android/dist")
  24. }
  25. google()
  26. jcenter()
  27. maven { url 'https://www.jitpack.io' }
  28. }
  29. }
  30. ext {
  31. buildToolsVersion = "30.0.0"
  32. minSdkVersion = 16
  33. compileSdkVersion = 30
  34. targetSdkVersion = 30
  35. def npmVersion = getNpmVersionArray()
  36. versionMajor = npmVersion[0]
  37. versionMinor = npmVersion[1]
  38. versionPatch = npmVersion[2]
  39. }
  40. def getNpmVersion() {
  41. def inputFile = new File("../package.json")
  42. def packageJson = new JsonSlurper().parseText(inputFile.text)
  43. return packageJson["version"]
  44. }
  45. def getNpmVersionArray() {
  46. def (major, minor, patch) = getNpmVersion().tokenize('.')
  47. return [Integer.parseInt(major), Integer.parseInt(minor), Integer.parseInt(patch)] as int[]
  48. }