buildscript {
	ext {
		springBootVersion = '1.5.10.RELEASE'
	}
	repositories {
		maven { url "https://maven.aliyun.com/repository/public/" }
		maven { url 'https://repo.spring.io/plugins-release' }
	}
	dependencies {
		classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
		classpath 'org.springframework:springloaded:1.2.6.RELEASE'
	}
}

apply plugin: 'java'
// 可生成maven  pom文件
// apply plugin: 'maven'
apply plugin: 'idea'
apply plugin: 'org.springframework.boot'
apply plugin: 'war'

idea {
	module {
		inheritOutputDirs = false
		outputDir file("$buildDir/classes/java/main")
		testOutputDir file("$buildDir/classes/java/test")
	}
}

group = 'com.bidding'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = 1.8

repositories {
	maven { url "https://maven.aliyun.com/repository/public/" }
}

//导出依赖jar包
task copyJars(type: Copy) {

	from configurations.runtime

	into 'build/libs' // 目标位置

}

dependencies {
	compile('org.springframework.boot:spring-boot-starter-data-redis')
	// 模版引擎
	compile('org.springframework.boot:spring-boot-starter-freemarker')
	compile('org.springframework.boot:spring-boot-starter-jdbc')
	compile('org.springframework.boot:spring-boot-starter-web')
	//json转换
	compile group: 'com.alibaba', name: 'fastjson', version: '1.2.17'
	// aop 权限校验和全局异常
	compile('org.springframework.boot:spring-boot-starter-aop')
	//mybatisplus
	compile group: 'com.baomidou', name: 'mybatisplus-spring-boot-starter', version: '1.0.3'
	//mybatisplus  代码生成器生产默认模版
	compile group: 'com.baomidou', name: 'mybatis-plus', version: '2.1-gamma'
	// mybatisplus  代码生成器  模版用到velocity  用完可注释
	compile group: 'org.apache.velocity', name: 'velocity', version: '1.7'
	// 文档转换
	compile (group: 'com.itextpdf', name: 'itextpdf', version: '5.5.11')
	compile (group: 'com.itextpdf.tool', name: 'xmlworker', version: '5.5.1')
	compile (group: 'org.xhtmlrenderer', name: 'flying-saucer-pdf', version: '9.1.5')
	compile (group: 'org.xhtmlrenderer', name: 'flying-saucer-pdf-itext5', version: '9.1.5')

	//安全 权限 依赖
	compile group: 'org.apache.shiro', name: 'shiro-spring', version: '1.7.1'
	// shiro登录信息存入redis的中间件
	compile group: 'org.crazycake', name: 'shiro-redis', version: '2.4.2.1-RELEASE'
	// shiro权限验证和模版引擎标签的中间件
	compile group: 'net.mingsoft', name: 'shiro-freemarker-tags', version: '0.1'
	// 日志
	compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.8.2'
	compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.8.2'
	// 工具
	compile group: 'org.apache.commons', name: 'commons-lang3', version: '3.6'
//	compile group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.2.1'
//	compile group: 'org.apache.httpcomponents', name: 'httpcore', version: '4.2.1'
	compile group: 'commons-io', name: 'commons-io', version: '2.5'
	compile group: 'commons-fileupload', name: 'commons-fileupload', version: '1.3.3'
	compile group: 'commons-lang', name: 'commons-lang', version: '2.6'
	// 数据库连接池
	compile group: 'mysql', name: 'mysql-connector-java', version: '8.0.12'
//	compile group: 'mysql', name: 'mysql-connector-java', version: '5.1.26'
	compile group: 'com.alibaba', name: 'druid-spring-boot-starter', version: '1.1.9'
	// 阿里oss
	compile (group: 'com.aliyun.oss', name: 'aliyun-sdk-oss', version: '3.8.0')
	//支付宝
	compile (group: 'com.alipay.sdk', name: 'alipay-sdk-java', version: '4.11.72.ALL')
	// 缩略图
	compile group: 'net.coobird', name: 'thumbnailator', version: '0.4.2'
	// swagger2
	compile group: 'io.springfox', name: 'springfox-swagger2', version: '2.7.0'
	compile group: 'io.springfox', name: 'springfox-swagger-ui', version: '2.7.0'
    //jpush
	compile group: 'cn.jpush.api', name: 'jpush-client', version: '3.3.12'
	compile group: 'cn.jpush.api', name: 'jiguang-common', version: '1.1.11'

	compile 'org.projectlombok:lombok:1.18.6'
//    编译有效，打包无效。替代旧版的 provider；
	compileOnly 'org.projectlombok:lombok:1.18.6'
	// gradle 5.0以上版本注解处理不再compile classpath，需要增加 annotation processor path
	annotationProcessor 'org.projectlombok:lombok:1.18.6'
	//forest
	compile group: 'com.dtflys.forest', name: 'forest-spring-boot-starter', version: '1.5.5'

	testCompile('org.springframework.boot:spring-boot-starter-test')
	//Hutool
	compile 'cn.hutool:hutool-all:5.4.7'
}
