Browse Source

Migrate build from Maven to Gradle.

master
Andreas Schildbach 5 years ago
parent
commit
de5db3cb98
10 changed files with 62 additions and 272 deletions
  1. 2
    0
      .gitignore
  2. 5
    0
      build.gradle
  3. 4
    4
      enabler/.gitignore
  4. 32
    0
      enabler/build.gradle
  5. 0
    111
      enabler/pom.xml
  6. 0
    73
      pom.xml
  7. 4
    4
      service/.gitignore
  8. 13
    0
      service/build.gradle
  9. 0
    80
      service/pom.xml
  10. 2
    0
      settings.gradle

+ 2
- 0
.gitignore View File

@@ -0,0 +1,2 @@
1
+build/
2
+.gradle/

+ 5
- 0
build.gradle View File

@@ -0,0 +1,5 @@
1
+allprojects {
2
+    repositories {
3
+        jcenter()
4
+    }
5
+}

+ 4
- 4
enabler/.gitignore View File

@@ -1,4 +1,4 @@
1
-target
2
-.classpath
3
-.project
4
-.settings
1
+/.classpath
2
+/.project
3
+/.settings/
4
+/bin/

+ 32
- 0
enabler/build.gradle View File

@@ -0,0 +1,32 @@
1
+apply plugin: 'java'
2
+apply plugin: 'eclipse'
3
+
4
+dependencies {
5
+    compile 'com.google.guava:guava:18.0'
6
+    compile 'org.slf4j:slf4j-api:1.7.12'
7
+    compile 'com.google.code.findbugs:jsr305:3.0.0'
8
+    compile 'org.json:json:20090211' // provided by Android
9
+    compile 'net.sf.kxml:kxml2:2.3.0' // provided by Android
10
+    testCompile 'junit:junit:4.11'
11
+    testRuntime 'org.slf4j:slf4j-jdk14:1.7.12'
12
+}
13
+
14
+sourceSets {
15
+    main {
16
+        java.srcDirs = ['src']
17
+        resources.srcDirs = ['src']
18
+    }
19
+    test {
20
+        java.srcDirs = ['test']
21
+        resources.srcDirs = ['test']
22
+    }
23
+}
24
+
25
+compileJava {
26
+    sourceCompatibility '1.5'
27
+    targetCompatibility '1.5'
28
+}
29
+
30
+test {
31
+    exclude 'de/schildbach/pte/live/**'
32
+}

+ 0
- 111
enabler/pom.xml View File

@@ -1,111 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-
3
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4
-	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
5
-	<modelVersion>4.0.0</modelVersion>
6
-
7
-	<groupId>de.schildbach.pte</groupId>
8
-	<artifactId>public-transport-enabler</artifactId>
9
-	<name>enabler</name>
10
-	<version>1.0-SNAPSHOT</version>
11
-
12
-	<parent>
13
-		<groupId>de.schildbach.pte</groupId>
14
-		<artifactId>base</artifactId>
15
-		<version>1</version>
16
-	</parent>
17
-
18
-	<dependencies>
19
-
20
-		<dependency>
21
-			<groupId>com.google.guava</groupId>
22
-			<artifactId>guava</artifactId>
23
-			<version>18.0</version>
24
-		</dependency>
25
-
26
-		<!-- org.slf4j.* -->
27
-		<dependency>
28
-			<groupId>org.slf4j</groupId>
29
-			<artifactId>slf4j-api</artifactId>
30
-			<version>1.7.12</version>
31
-		</dependency>
32
-
33
-		<!-- javax.annotation.* -->
34
-		<dependency>
35
-			<groupId>com.google.code.findbugs</groupId>
36
-			<artifactId>jsr305</artifactId>
37
-			<version>3.0.0</version>
38
-		</dependency>
39
-
40
-		<dependency>
41
-			<groupId>org.json</groupId>
42
-			<artifactId>json</artifactId>
43
-			<version>20090211</version>
44
-			<scope>provided</scope>
45
-		</dependency>
46
-
47
-		<dependency>
48
-			<groupId>net.sf.kxml</groupId>
49
-			<artifactId>kxml2</artifactId>
50
-			<version>2.3.0</version>
51
-			<scope>provided</scope>
52
-		</dependency>
53
-
54
-		<dependency>
55
-			<groupId>junit</groupId>
56
-			<artifactId>junit</artifactId>
57
-			<version>4.11</version>
58
-			<scope>test</scope>
59
-		</dependency>
60
-
61
-		<!-- org.slf4j.* -->
62
-		<dependency>
63
-			<groupId>org.slf4j</groupId>
64
-			<artifactId>slf4j-jdk14</artifactId>
65
-			<version>1.7.12</version>
66
-			<scope>test</scope>
67
-		</dependency>
68
-
69
-	</dependencies>
70
-
71
-	<build>
72
-		<sourceDirectory>src</sourceDirectory>
73
-		<testSourceDirectory>test</testSourceDirectory>
74
-		<resources>
75
-			<resource>
76
-				<directory>src</directory>
77
-				<excludes>
78
-					<exclude>**/*.java</exclude>
79
-				</excludes>
80
-			</resource>
81
-		</resources>
82
-		<testResources>
83
-			<testResource>
84
-				<directory>test</directory>
85
-				<excludes>
86
-					<exclude>**/*.java</exclude>
87
-				</excludes>
88
-			</testResource>
89
-		</testResources>
90
-		<plugins>
91
-			<plugin>
92
-				<groupId>org.apache.maven.plugins</groupId>
93
-				<artifactId>maven-compiler-plugin</artifactId>
94
-				<configuration>
95
-					<source>1.5</source>
96
-					<target>1.5</target>
97
-				</configuration>
98
-			</plugin>
99
-			<plugin>
100
-				<groupId>org.apache.maven.plugins</groupId>
101
-				<artifactId>maven-surefire-plugin</artifactId>
102
-				<configuration>
103
-					<excludes>
104
-						<exclude>de/schildbach/pte/live/**</exclude>
105
-					</excludes>
106
-				</configuration>
107
-			</plugin>
108
-		</plugins>
109
-	</build>
110
-
111
-</project>

+ 0
- 73
pom.xml View File

@@ -1,73 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-
3
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4
-	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
5
-	<modelVersion>4.0.0</modelVersion>
6
-
7
-	<groupId>de.schildbach.pte</groupId>
8
-	<artifactId>base</artifactId>
9
-	<name>base</name>
10
-	<version>1</version>
11
-	<packaging>pom</packaging>
12
-
13
-	<modules>
14
-		<module>enabler</module>
15
-		<module>service</module>
16
-	</modules>
17
-
18
-	<developers>
19
-		<developer>
20
-			<name>Andreas Schildbach</name>
21
-			<email>andreas@schildbach.de</email>
22
-			<url>http://schildbach.de</url>
23
-		</developer>
24
-	</developers>
25
-
26
-	<scm>
27
-		<url>http://code.google.com/p/public-transport-enabler/source/checkout</url>
28
-		<connection>scm:git:https://code.google.com/p/public-transport-enabler/</connection>
29
-	</scm>
30
-
31
-	<issueManagement>
32
-		<url>http://code.google.com/p/public-transport-enabler/issues/list</url>
33
-	</issueManagement>
34
-
35
-	<mailingLists>
36
-		<mailingList>
37
-			<name>public-transport-enabler-discuss Google Group</name>
38
-			<post>https://groups.google.com/forum/#!forum/public-transport-enabler-discuss</post>
39
-		</mailingList>
40
-	</mailingLists>
41
-
42
-	<build>
43
-		<pluginManagement>
44
-			<plugins>
45
-				<plugin>
46
-					<groupId>org.apache.maven.plugins</groupId>
47
-					<artifactId>maven-compiler-plugin</artifactId>
48
-					<version>3.0</version>
49
-				</plugin>
50
-				<plugin>
51
-					<groupId>org.apache.maven.plugins</groupId>
52
-					<artifactId>maven-surefire-plugin</artifactId>
53
-					<version>2.12.4</version>
54
-				</plugin>
55
-			</plugins>
56
-		</pluginManagement>
57
-		<plugins>
58
-			<plugin>
59
-				<groupId>org.apache.maven.plugins</groupId>
60
-				<artifactId>maven-release-plugin</artifactId>
61
-				<version>2.3.1</version>
62
-				<configuration>
63
-					<pushChanges>false</pushChanges>
64
-				</configuration>
65
-			</plugin>
66
-		</plugins>
67
-	</build>
68
-
69
-	<properties>
70
-		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
71
-	</properties>
72
-
73
-</project>

+ 4
- 4
service/.gitignore View File

@@ -1,4 +1,4 @@
1
-target
2
-.classpath
3
-.project
4
-.settings
1
+/.classpath
2
+/.project
3
+/.settings/
4
+/bin/

+ 13
- 0
service/build.gradle View File

@@ -0,0 +1,13 @@
1
+apply plugin: 'java'
2
+apply plugin: 'eclipse'
3
+
4
+dependencies {
5
+    compile project(':enabler')
6
+    compile 'org.springframework:spring-webmvc:3.1.0.RELEASE'
7
+    compile 'org.codehaus.jackson:jackson-mapper-asl:1.9.4'
8
+}
9
+
10
+compileJava {
11
+    sourceCompatibility '1.6'
12
+    targetCompatibility '1.6'
13
+}

+ 0
- 80
service/pom.xml View File

@@ -1,80 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-
3
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4
-	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
5
-	<modelVersion>4.0.0</modelVersion>
6
-
7
-	<groupId>de.schildbach.pte</groupId>
8
-	<artifactId>public-transport-service</artifactId>
9
-	<name>service</name>
10
-	<version>1.0-SNAPSHOT</version>
11
-	<packaging>war</packaging>
12
-
13
-	<parent>
14
-		<groupId>de.schildbach.pte</groupId>
15
-		<artifactId>base</artifactId>
16
-		<version>1</version>
17
-	</parent>
18
-
19
-	<developers>
20
-		<developer>
21
-			<name>Andreas Schildbach</name>
22
-			<email>andreas@schildbach.de</email>
23
-		</developer>
24
-	</developers>
25
-
26
-	<dependencies>
27
-
28
-		<dependency>
29
-			<groupId>de.schildbach.pte</groupId>
30
-			<artifactId>public-transport-enabler</artifactId>
31
-			<version>1.0-SNAPSHOT</version>
32
-		</dependency>
33
-
34
-		<dependency>
35
-			<groupId>org.json</groupId>
36
-			<artifactId>json</artifactId>
37
-			<version>20090211</version>
38
-		</dependency>
39
-
40
-		<dependency>
41
-			<groupId>net.sf.kxml</groupId>
42
-			<artifactId>kxml2</artifactId>
43
-			<version>2.3.0</version>
44
-		</dependency>
45
-
46
-		<dependency>
47
-			<groupId>org.springframework</groupId>
48
-			<artifactId>spring-webmvc</artifactId>
49
-			<version>3.1.0.RELEASE</version>
50
-		</dependency>
51
-
52
-		<dependency>
53
-			<groupId>org.codehaus.jackson</groupId>
54
-			<artifactId>jackson-mapper-asl</artifactId>
55
-			<version>1.9.4</version>
56
-		</dependency>
57
-
58
-		<dependency>
59
-			<groupId>junit</groupId>
60
-			<artifactId>junit</artifactId>
61
-			<version>4.11</version>
62
-			<scope>test</scope>
63
-		</dependency>
64
-
65
-	</dependencies>
66
-
67
-	<build>
68
-		<plugins>
69
-			<plugin>
70
-				<groupId>org.apache.maven.plugins</groupId>
71
-				<artifactId>maven-compiler-plugin</artifactId>
72
-				<configuration>
73
-					<source>1.6</source>
74
-					<target>1.6</target>
75
-				</configuration>
76
-			</plugin>
77
-		</plugins>
78
-	</build>
79
-
80
-</project>

+ 2
- 0
settings.gradle View File

@@ -0,0 +1,2 @@
1
+include 'enabler'
2
+include 'service'

Loading…
Cancel
Save