Commit 2116739c authored by Matija Obreza's avatar Matija Obreza
Browse files

Packaging

parent 3e076f58
......@@ -12,17 +12,34 @@
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
</license>
</licenses>
<organization>
<name>Global Crop Diversity Trust</name>
<url>https://www.croptrust.org</url>
</organization>
<developers>
<developer>
<name>Matija Obreza</name>
<email>matija.obreza@croptrust.org</email>
<organization>Global Crop Diversity Trust</organization>
<organizationUrl>http://www.croptrust.org</organizationUrl>
</developer>
</developers>
<scm>
<connection>https://bitbucket.org/genesys2/geo-tools.git</connection>
<developerConnection>scm:git:git@bitbucket.org:genesys2/geo-tools.git</developerConnection>
<url>git@bitbucket.org:genesys2/geo-tools.git</url>
</scm>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jdk.target>1.8</jdk.target>
<jdk.source>1.8</jdk.source>
<!-- use the latest snapshot -->
<geotools.version>15-SNAPSHOT</geotools.version>
<jar.mainclass>org.genesys.geotools.LandOrSeaCLI</jar.mainclass>
</properties>
<dependencies>
......@@ -48,10 +65,10 @@
<version>${geotools.version}</version>
</dependency>
<dependency>
<groupId>org.geotools</groupId>
<artifactId>gt-swing</artifactId>
<version>${geotools.version}</version>
</dependency>
<groupId>org.geotools</groupId>
<artifactId>gt-swing</artifactId>
<version>${geotools.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
......@@ -86,6 +103,52 @@
<testFailureIgnore>false</testFailureIgnore>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.8</version>
<executions>
<execution>
<id>copy-dependencies</id>
<phase>prepare-package</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>${project.build.directory}/lib</outputDirectory>
<overWriteReleases>true</overWriteReleases>
<overWriteSnapshots>true</overWriteSnapshots>
<overWriteIfNewer>true</overWriteIfNewer>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.5</version>
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
<useUniqueVersions>false</useUniqueVersions>
<classpathPrefix>lib/</classpathPrefix>
<mainClass>${jar.mainclass}</mainClass>
</manifest>
<manifestEntries>
<version>${project.version}</version>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.5.1</version>
<configuration>
<pushChanges>false</pushChanges>
</configuration>
</plugin>
</plugins>
</build>
......
......@@ -22,6 +22,10 @@ public class LandOrSeaCLI {
String input = null;
do {
input = br.readLine();
if ("q".equals(input))
break;
Matcher matcher = pattern.matcher(input);
if (matcher.find()) {
float latitude = Float.parseFloat(matcher.group(1).replace(",", "."));
......@@ -36,6 +40,6 @@ public class LandOrSeaCLI {
} else {
System.err.println("Invalid format: " + input);
}
} while (input == null || !"q".equals(input));
} while (input != null && !"q".equals(input));
}
}
......@@ -39,7 +39,7 @@ public class Snippet {
} else {
System.err.println("Invalid format: " + input);
}
} while (input == null || !"q".equals(input));
} while (input != null && !"q".equals(input));
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment