From 3f99d73f78714c523fbea3243f29a90cdd85619d Mon Sep 17 00:00:00 2001 From: Jason von Nieda Date: Mon, 18 Sep 2017 02:22:52 -0500 Subject: [PATCH] Add deployment configuration to pom for releasing on Central. Add license file. Add release info. Add simple test to make sure library loads. Release 0.0.2-2 --- .gitignore | 3 + LICENSE.txt | 16 +++ RELEASE.md | 4 + pom.xml | 183 +++++++++++++++++++++++------ src/test/java/LoadLibraryTest.java | 9 ++ 5 files changed, 179 insertions(+), 36 deletions(-) create mode 100644 LICENSE.txt create mode 100644 RELEASE.md create mode 100644 src/test/java/LoadLibraryTest.java diff --git a/.gitignore b/.gitignore index 4e71f47..cdf32af 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,6 @@ target openpnp-capture dependency-reduced-pom.xml +.classpath +.project +.settings diff --git a/LICENSE.txt b/LICENSE.txt new file mode 100644 index 0000000..d0e2e9f --- /dev/null +++ b/LICENSE.txt @@ -0,0 +1,16 @@ +Copyright 2017 Jason von nieda + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and +associated documentation files (the "Software"), to deal in the Software without restriction, +including without limitation the rights to use, copy, modify, merge, publish, distribute, +sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or +substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING +BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/RELEASE.md b/RELEASE.md new file mode 100644 index 0000000..8c72918 --- /dev/null +++ b/RELEASE.md @@ -0,0 +1,4 @@ +1. Choose an OpenPnP Capture release from https://github.com/openpnp/openpnp-capture/releases. +2. `./scripts/download-openpnp-capture.sh ` +3. Set versions in `pom.xml`. Should match release. Append `-n` for sub-releases. +4. `mvn clean deploy` \ No newline at end of file diff --git a/pom.xml b/pom.xml index 6570758..f0a104a 100644 --- a/pom.xml +++ b/pom.xml @@ -1,20 +1,56 @@ 4.0.0 - openpnp-capture + org.openpnp openpnp-capture-java - 0.0.1-SNAPSHOT + 0.0.2-2 UTF-8 + + + MIT License + https://opensource.org/licenses/MIT + + + + OpenPnP Capture Java Bindings + OpenPnP Capture Java with all binaries included, packaged for Maven. + http://github.com/openpnp/openpnp-capture-java + + + https://github.com/openpnp/openpnp-capture + scm:git:http://github.com/openpnp/openpnp-capture.git + scm:git:http://github.com/openpnp/openpnp-capture.git + v0.0.2 + + + + GitHub + http://github.com/openpnp/opencv/issues + + + + + vonnieda + Jason von Nieda + jason@vonnieda.org + OpenPnP + http://openpnp.org + + maintainer + + + + - - openpnp-capture/binaries - - - - + + openpnp-capture/binaries + + + + org.apache.maven.plugins maven-compiler-plugin @@ -42,8 +78,8 @@ - + org.codehaus.mojo build-helper-maven-plugin @@ -66,29 +102,32 @@ - org.apache.maven.plugins - maven-shade-plugin - 3.0.0 - - - - - package - - shade - - - - - org.openpnp.capture.OpenPnpCapture - - - - - - + org.apache.maven.plugins + maven-shade-plugin + 3.0.0 + + + + + package + + shade + + + + + org.openpnp.capture.OpenPnpCapture + + + true + shaded + + + + - + org.apache.maven.plugins maven-resources-plugin @@ -98,11 +137,15 @@ - + org.apache.maven.plugins maven-checkstyle-plugin 2.17 + + ${project.build.sourceDirectory} + com.puppycrawl.tools @@ -123,15 +166,15 @@ - + - + - + @@ -147,6 +190,68 @@ + + + + org.apache.maven.plugins + maven-source-plugin + 2.2.1 + + + attach-sources + + jar-no-fork + + + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + 2.9.1 + + -Xdoclint:none + + + + attach-javadocs + + jar + + + + + + + + org.sonatype.plugins + nexus-staging-maven-plugin + 1.6.7 + true + + ossrh + https://oss.sonatype.org/ + true + + + + + + org.apache.maven.plugins + maven-gpg-plugin + 1.5 + + + sign-artifacts + verify + + sign + + + + @@ -155,5 +260,11 @@ jnaerator-runtime 0.12 + + junit + junit + 4.11 + test + \ No newline at end of file diff --git a/src/test/java/LoadLibraryTest.java b/src/test/java/LoadLibraryTest.java new file mode 100644 index 0000000..0fc94ce --- /dev/null +++ b/src/test/java/LoadLibraryTest.java @@ -0,0 +1,9 @@ +import org.junit.Test; +import org.openpnp.capture.OpenPnpCapture; + +public class LoadLibraryTest { + @Test + public void testLoadLibrary() { + new OpenPnpCapture(); + } +}