配置阿里云gradle

Spring Boot应用搭建
本文介绍了一个使用Spring Boot搭建的应用案例,通过Gradle构建工具配置了依赖管理及插件,包括Spring Boot Gradle插件的设置,并引入了Web启动器和测试启动器。

build.gradle

buildscript {
    ext {
	springBootVersion = '1.5.15.BUILD-SNAPSHOT'
    }
    repositories {
	// mavenCentral()
	maven {url "http://maven.aliyun.com/nexus/content/groups/public/" }
	maven { url "https://repo.spring.io/snapshot" }
	maven { url "https://repo.spring.io/milestone" }
    }
    dependencies {
	classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
    }
}

apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'org.springframework.boot'

group = 'com.waylau.spring.boot.blog'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = 1.8

repositories {
    // mavenCentral()
    maven {url "http://maven.aliyun.com/nexus/content/groups/public/" }
    maven { url "https://repo.spring.io/snapshot" }
    maven { url "https://repo.spring.io/milestone" }
}


dependencies {
    compile('org.springframework.boot:spring-boot-starter-web')
    testCompile('org.springframework.boot:spring-boot-starter-test')
}

  

转载于:https://www.cnblogs.com/mingzhanghui/p/9193652.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值