build.gradle 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. buildscript {
  2. ext {
  3. springBootVersion = '2.0.6.RELEASE'
  4. }
  5. repositories {
  6. mavenLocal()
  7. maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'}
  8. }
  9. dependencies {
  10. classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
  11. }
  12. }
  13. //apply plugin: 'war'
  14. apply plugin: 'java'
  15. apply plugin: 'org.springframework.boot'
  16. apply plugin: 'io.spring.dependency-management'
  17. archivesBaseName = "water-api-${releaseTime()}"
  18. group = 'com.bz'
  19. //version = '0.0.1-SNAPSHOT'
  20. sourceCompatibility = 1.8
  21. targetCompatibility = 1.8
  22. jar {
  23. version = '0.0.1'
  24. manifest {
  25. attributes "Manifest-Version": 1.0,
  26. 'Main-Class': 'com.bz.smart_city.SmartCityApplication'
  27. }
  28. }
  29. repositories {
  30. mavenLocal()
  31. maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'}
  32. }
  33. configurations {
  34. compileOnly {
  35. extendsFrom annotationProcessor
  36. }
  37. }
  38. dependencies {
  39. compileOnly 'org.projectlombok:lombok:1.18.10'
  40. annotationProcessor 'org.projectlombok:lombok:1.18.10'
  41. testCompileOnly 'org.projectlombok:lombok:1.18.10'
  42. testAnnotationProcessor 'org.projectlombok:lombok:1.18.10'
  43. implementation('org.springframework.boot:spring-boot-starter-security')
  44. implementation('org.springframework.boot:spring-boot-starter-web')
  45. implementation('org.springframework.boot:spring-boot-starter-thymeleaf')
  46. implementation('org.springframework.boot:spring-boot-starter-aop')
  47. implementation('org.springframework.boot:spring-boot-starter-validation')
  48. implementation('org.springframework.boot:spring-boot-starter-amqp')
  49. implementation('org.springframework.kafka:spring-kafka')
  50. implementation 'org.springframework.boot:spring-boot-starter-data-mongodb'
  51. compile('mysql:mysql-connector-java')
  52. //数据源连接池
  53. //compile('com.alibaba:druid:1.1.6')
  54. compile('com.alibaba:druid-spring-boot-starter:1.1.9')
  55. //swagger在线接口文档生成工具
  56. compile('io.springfox:springfox-swagger2:2.7.0')
  57. compile('io.springfox:springfox-swagger-ui:2.7.0')
  58. //分页插件
  59. //compile('com.github.pagehelper:pagehelper:4.1.0')
  60. compile('com.github.pagehelper:pagehelper-spring-boot-starter:1.2.10')
  61. compile ('org.apache.httpcomponents:httpclient:4.5.6')
  62. //json工具
  63. compile('com.alibaba:fastjson:1.2.41')
  64. compile('io.jsonwebtoken:jjwt:0.9.0')
  65. //redis
  66. compile('org.springframework.boot:spring-boot-starter-data-redis')
  67. {
  68. exclude group: 'io.lettuce'
  69. }
  70. compile('redis.clients:jedis')
  71. compile('org.apache.commons:commons-pool2')
  72. compileOnly('org.projectlombok:lombok')
  73. testImplementation('org.springframework.boot:spring-boot-starter-test')
  74. compile('org.apache.commons:commons-lang3:3.4')
  75. //poi
  76. compile 'org.apache.poi:poi:3.17'
  77. compile 'org.apache.poi:poi-ooxml:3.17'
  78. compile 'org.apache.poi:poi-ooxml-schemas:3.17'
  79. //jxls
  80. //compile 'org.jxls.jxls:2.4.6'
  81. compile 'org.jxls:jxls-poi:1.0.16'
  82. //activiti
  83. compile('org.activiti:activiti-spring-boot-starter-basic:5.22.0')
  84. compile('dom4j:dom4j:1.6.1')
  85. // quartz
  86. compile('org.springframework.boot:spring-boot-starter-quartz')
  87. //腾讯云
  88. compile('com.github.qcloudsms:qcloudsms:1.0.6')
  89. //netty
  90. compile ('io.netty:netty-all:4.1.30.Final')
  91. compile('org.bouncycastle:bcprov-jdk16:1.46')
  92. //阿里云
  93. compile('com.aliyun:aliyun-java-sdk-core:4.1.0')
  94. //jdom
  95. compile('org.jdom:jdom:1.1')
  96. }
  97. tasks.withType(JavaCompile) {
  98. options.encoding = 'UTF-8'
  99. }
  100. def releaseTime() {
  101. return new Date().format("yyyyMMdd", TimeZone.getTimeZone("GMT+08:00"))
  102. }
  103. allprojects {
  104. gradle.projectsEvaluated {
  105. tasks.withType(JavaCompile) {
  106. options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation" }
  107. }
  108. }