Skip to content

Commit 5e97591

Browse files
authored
Merge pull request shannah#19 from shannah/feature/maven
Feature/maven
2 parents 47fe20c + 797baef commit 5e97591

36 files changed

+2445
-1365
lines changed

README.md

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,35 +10,38 @@ Apache 2.0 License
1010

1111
## Requirements
1212

13-
1. Java11 or Higher on OS X
13+
1. Java 11 or Higher on OS X
1414
2. JNA
1515

16-
## Installation
16+
## Getting Started
1717

1818
1. Check out the project and use `mvn clean install` (for debug builds) or `mvn clean install -Drelease=true` (for release builds) to build it
1919
2. include it as a maven depencency in your project:
2020

2121
```xml
22-
<groupId>io.spot-next</groupId>
23-
<artifactId>java-objectivec-bridge</artifactId>
24-
<version>1.0-SNAPSHOT</version>
22+
<dependency>
23+
<groupId>ca.weblite</groupId>
24+
<artifactId>java-objc-bridge</artifactId>
25+
<version>1.1-SNAPSHOT</version>
26+
</dependency>
2527
```
2628

2729
## Examples
2830

2931
* [Sample wrapper of NSOpenPanel and NSSavePanel](https://gist.github.com/shannah/65007754c2b0f8add4f7)
30-
* [Example using WebKit and .nib file](https://github.com/shannah/Java-Objective-C-Bridge/blob/master/java/test/ca/weblite/objc/TestWebView.java)
31-
* [Loading Nib File](https://github.com/shannah/Java-Objective-C-Bridge/blob/master/java/test/ca/weblite/objc/LoadNibSample.java)
32-
* [Wrapper for NSProcessInfo to Solve App Nap Problem](java/test/ca/weblite/objc/NSProcessInfoUtils.java)
32+
* [Example using WebKit and .nib file](src/test/java/ca/weblite/objc/TestWebView.java)
33+
* [Loading Nib File](src/test/java/ca/weblite/objc/LoadNibSample.java)
34+
* [Wrapper for NSProcessInfo to Solve App Nap Problem](src/test/java/ca/weblite/objc/NSProcessInfoUtils.java)
3335

3436
## JavaDocs & Documentation
3537

36-
* [Documentation](http://solutions.weblite.ca/java-objective-c-bridge/docs)
38+
* [Documentation](http://solutions.weblite.ca/maven/java-objc-bridge/apidocs/index.html)
3739
* Read a [blog post](http://www.shannah.ca/blog/?p=219) about the motivation for this project.
3840

3941
## Contact
4042

41-
* [Mailing List](http://java.net/projects/java-objc-bridge/lists)
43+
* Post your questions in the [Java-Objective-C Google Group](https://groups.google.com/forum/#!forum/java-objective-c-bridge)
44+
* Post bugs and feature requests to the [issue tracker](https://github.com/shannah/Java-Objective-C-Bridge/issues)
4245

4346
## Credits
4447

pom.xml

Lines changed: 173 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,6 @@
77
<version>1.1-SNAPSHOT</version>
88
<name>Java-Objective-C-Bridge</name>
99
<description>A thin bridge that allows for two-way communication from Java to Objective-C.</description>
10-
<licenses>
11-
<license>
12-
<name>Apache 2.0 License</name>
13-
</license>
14-
</licenses>
1510

1611
<profiles>
1712
<profile>
@@ -23,10 +18,28 @@
2318
<properties>
2419
<xcodeScheme>Release</xcodeScheme>
2520
</properties>
21+
<build>
22+
<plugins>
23+
<plugin>
24+
<groupId>org.apache.maven.plugins</groupId>
25+
<artifactId>maven-javadoc-plugin</artifactId>
26+
</plugin>
27+
28+
<plugin>
29+
<groupId>org.apache.maven.plugins</groupId>
30+
<artifactId>maven-source-plugin</artifactId>
31+
</plugin>
32+
<plugin>
33+
<groupId>org.apache.maven.plugins</groupId>
34+
<artifactId>maven-gpg-plugin</artifactId>
35+
</plugin>
36+
</plugins>
37+
</build>
2638
</profile>
2739
</profiles>
2840

2941
<properties>
42+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
3043
<maven.compiler.target>11</maven.compiler.target>
3144
<maven.compiler.source>11</maven.compiler.source>
3245
<xcodeScheme>Debug</xcodeScheme>
@@ -49,47 +62,63 @@
4962
</developer>
5063
</developers>
5164

65+
<licenses>
66+
<license>
67+
<name>Apache License, Version 2.0</name>
68+
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
69+
<distribution>repo</distribution>
70+
</license>
71+
</licenses>
72+
73+
<inceptionYear>2012</inceptionYear>
74+
75+
<organization>
76+
<name>Web Lite Solutions Corp.</name>
77+
<url>http://solutions.weblite.ca</url>
78+
</organization>
79+
5280
<issueManagement>
5381
<system>github</system>
5482
<url>https://github.com/shannah/Java-Objective-C-Bridge/issues</url>
5583
</issueManagement>
5684

5785
<url>https://github.com/shannah/Java-Objective-C-Bridge</url>
5886

59-
60-
6187
<scm>
88+
<connection>scm:git:https://github.com/shannah/Java-Objective-C-Bridge.git</connection>
89+
<developerConnection>scm:git:https://github.com/shannah/Java-Objective-C-Bridge.git</developerConnection>
90+
<tag>HEAD</tag>
6291
<url>https://github.com/shannah/Java-Objective-C-Bridge</url>
6392
</scm>
6493

94+
<distributionManagement>
95+
<snapshotRepository>
96+
<id>ossrh</id>
97+
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
98+
</snapshotRepository>
99+
<repository>
100+
<id>weblite-internal</id>
101+
<name>Web Lite Internal Repository</name>
102+
<url>scp://maven.weblite.ca/swete-data-recovery/home/maven/</url>
103+
104+
</repository>
105+
<site>
106+
<id>weblite-solutions</id>
107+
<url>scp://solutions.weblite.ca/home/weblite_ca/solutions.weblite.ca/maven/java-objc-bridge</url>
108+
</site>
109+
</distributionManagement>
65110

66111
<build>
112+
<extensions>
113+
<extension>
114+
<groupId>org.apache.maven.wagon</groupId>
115+
<artifactId>wagon-ssh</artifactId>
116+
<version>2.4</version>
117+
</extension>
118+
</extensions>
67119
<plugins>
68-
<plugin>
69-
<artifactId>maven-resources-plugin</artifactId>
70-
<version>3.1.0</version>
71-
<executions>
72-
<execution>
73-
<id>copy-native-libs</id>
74-
<phase>process-resources</phase>
75-
<goals>
76-
<goal>copy-resources</goal>
77-
</goals>
78-
<configuration>
79-
<resources>
80-
<resource>
81-
<directory>${basedir}/target/native/</directory>
82-
<filtering>false</filtering>
83-
</resource>
84-
</resources>
85-
<outputDirectory>${basedir}/target/classes/ca/weblite/objc</outputDirectory>
86-
</configuration>
87-
</execution>
88-
</executions>
89-
</plugin>
90-
91-
<!-- -->
92120

121+
<!-- native build -->
93122
<plugin>
94123
<groupId>org.codehaus.mojo</groupId>
95124
<artifactId>exec-maven-plugin</artifactId>
@@ -116,6 +145,31 @@
116145
</configuration>
117146
</plugin>
118147

148+
<!-- copy native libs -->
149+
<plugin>
150+
<artifactId>maven-resources-plugin</artifactId>
151+
<version>3.1.0</version>
152+
<executions>
153+
<execution>
154+
<id>copy-native-libs</id>
155+
<phase>process-resources</phase>
156+
<goals>
157+
<goal>copy-resources</goal>
158+
</goals>
159+
<configuration>
160+
<resources>
161+
<resource>
162+
<directory>${basedir}/target/native/</directory>
163+
<filtering>false</filtering>
164+
</resource>
165+
</resources>
166+
<outputDirectory>${basedir}/target/classes/ca/weblite/objc</outputDirectory>
167+
</configuration>
168+
</execution>
169+
</executions>
170+
</plugin>
171+
172+
<!-- add java 11 module name to manifest -->
119173
<plugin>
120174
<groupId>org.apache.maven.plugins</groupId>
121175
<artifactId>maven-jar-plugin</artifactId>
@@ -128,7 +182,94 @@
128182
</archive>
129183
</configuration>
130184
</plugin>
185+
186+
<!-- deployment -->
187+
<plugin>
188+
<groupId>org.sonatype.plugins</groupId>
189+
<artifactId>nexus-staging-maven-plugin</artifactId>
190+
<version>1.6.8</version>
191+
<extensions>true</extensions>
192+
<configuration>
193+
<serverId>ossrh</serverId>
194+
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
195+
<autoReleaseAfterClose>true</autoReleaseAfterClose>
196+
</configuration>
197+
</plugin>
131198
</plugins>
199+
200+
<pluginManagement>
201+
<plugins>
202+
<plugin>
203+
<groupId>org.apache.maven.plugins</groupId>
204+
<artifactId>maven-source-plugin</artifactId>
205+
<version>3.1.0</version>
206+
<executions>
207+
<execution>
208+
<id>attach-sources</id>
209+
<goals>
210+
<goal>jar-no-fork</goal>
211+
</goals>
212+
</execution>
213+
</executions>
214+
</plugin>
215+
216+
<plugin>
217+
<groupId>org.apache.maven.plugins</groupId>
218+
<artifactId>maven-javadoc-plugin</artifactId>
219+
<version>3.1.1</version>
220+
<configuration>
221+
<failOnError>false</failOnError>
222+
<!-- <additionalparam>-Xdoclint:none</additionalparam> -->
223+
<additionalOptions>--allow-script-in-comments </additionalOptions>
224+
<useStandardDocletOptions>false</useStandardDocletOptions>
225+
226+
<quiet>true</quiet>
227+
<!-- does not work with revision property! -->
228+
<ignoreClirr>true</ignoreClirr>
229+
230+
<detectLinks>false</detectLinks>
231+
<detectOfflineLinks>false</detectOfflineLinks>
232+
<doclint>all,-html,-syntax</doclint>
233+
<version>false</version>
234+
<nosince>true</nosince>
235+
<author>false</author>
236+
<defaultAuthor>mojo2012</defaultAuthor>
237+
<defaultVersion>1.0</defaultVersion>
238+
<level>public</level>
239+
</configuration>
240+
<executions>
241+
<execution>
242+
<id>attach-javadocs</id>
243+
<goals>
244+
<goal>jar</goal>
245+
</goals>
246+
</execution>
247+
</executions>
248+
</plugin>
249+
250+
<plugin>
251+
<groupId>org.apache.maven.plugins</groupId>
252+
<artifactId>maven-gpg-plugin</artifactId>
253+
<version>1.6</version>
254+
<configuration>
255+
<!-- This is necessary for gpg to not try to use the pinentry programs -->
256+
<gpgArguments>
257+
<arg>--pinentry-mode</arg>
258+
<arg>loopback</arg>
259+
</gpgArguments>
260+
</configuration>
261+
<executions>
262+
<execution>
263+
<id>sign-artifacts</id>
264+
<phase>verify</phase>
265+
<goals>
266+
<goal>sign</goal>
267+
</goals>
268+
</execution>
269+
</executions>
270+
</plugin>
271+
</plugins>
272+
</pluginManagement>
132273
</build>
133274

134275
<dependencies>
@@ -138,12 +279,6 @@
138279
<version>5.4.0</version>
139280
</dependency>
140281

141-
<!-- <dependency> -->
142-
<!-- <groupId>com.nativelibs4java</groupId> -->
143-
<!-- <artifactId>jnaerator-rococoa-runtime</artifactId> -->
144-
<!-- <version>0.12</version> -->
145-
<!-- </dependency> -->
146-
147282
<dependency>
148283
<groupId>org.junit.jupiter</groupId>
149284
<artifactId>junit-jupiter-api</artifactId>
@@ -157,6 +292,5 @@
157292
<scope>test</scope>
158293
</dependency>
159294

160-
161295
</dependencies>
162-
</project>
296+
</project>

0 commit comments

Comments
 (0)