change project to maven

This commit is contained in:
limqhz
2021-03-02 23:50:51 +08:00
parent 28fe094cef
commit 0ed96b9e24
19 changed files with 512 additions and 561 deletions

View File

@@ -1,45 +0,0 @@
buildscript {
ext {
springBootVersion = '1.5.6.RELEASE'
}
repositories {
maven {
url 'https://maven.aliyun.com/repository/public'
}
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
}
}
group 'smartvenue'
version '2.0.0'
apply plugin: 'java'
apply plugin: 'org.springframework.boot'
sourceCompatibility = 1.8
repositories {
//mavenCentral()
maven {
url 'https://maven.aliyun.com/repository/public'
}
}
jar {
baseName = 'sv-api'
}
ext {
nettyVersion = '4.1.10.Final'
}
dependencies {
compile fileTree(include: '*.jar', dir: 'src/libs')
compile project(':service')
compile "io.netty:netty-all:${nettyVersion}"
compile 'mysql:mysql-connector-java:6.0.6'
}
tasks.withType(JavaCompile) {
options.encoding = "UTF-8"
}

59
api/pom.xml Normal file
View File

@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<parent>
<groupId>smartvenue</groupId>
<artifactId>smartvenue-parent</artifactId>
<version>2.0.0</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>sv-api</artifactId>
<version>${smartvenue.version}</version>
<dependencies>
<dependency>
<groupId>smartvenue</groupId>
<artifactId>sv-service</artifactId>
</dependency>
<dependency>
<groupId>io.netty</groupId>
<artifactId>netty-all</artifactId>
<version>4.1.10.Final</version>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>6.0.6</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>${spring.boot.version}</version>
<configuration>
<outputDirectory>../target/boot/api</outputDirectory>
<classifier>executable</classifier>
</configuration>
<executions>
<execution>
<goals>
<goal>repackage</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>