You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@opennlp.apache.org by co...@apache.org on 2016/12/27 03:00:14 UTC

[1/3] opennlp git commit: Distributable should include all the dependencies

Repository: opennlp
Updated Branches:
  refs/heads/trunk 8e488a514 -> b12187901


Distributable should include all the dependencies

Changed the bin assembly to include dependencies for BRAT and Morfologik.

See issue OPENNLP-895


Project: http://git-wip-us.apache.org/repos/asf/opennlp/repo
Commit: http://git-wip-us.apache.org/repos/asf/opennlp/commit/8d0d5324
Tree: http://git-wip-us.apache.org/repos/asf/opennlp/tree/8d0d5324
Diff: http://git-wip-us.apache.org/repos/asf/opennlp/diff/8d0d5324

Branch: refs/heads/trunk
Commit: 8d0d5324893ba2ef047f18cfdac4d1281310c95e
Parents: 8e488a5
Author: William Colen <co...@apache.org>
Authored: Mon Dec 26 15:20:00 2016 -0200
Committer: William Colen <co...@apache.org>
Committed: Mon Dec 26 15:20:00 2016 -0200

----------------------------------------------------------------------
 opennlp-distr/src/main/assembly/bin.xml | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/opennlp/blob/8d0d5324/opennlp-distr/src/main/assembly/bin.xml
----------------------------------------------------------------------
diff --git a/opennlp-distr/src/main/assembly/bin.xml b/opennlp-distr/src/main/assembly/bin.xml
index 5ec7ad7..4ed17f8 100644
--- a/opennlp-distr/src/main/assembly/bin.xml
+++ b/opennlp-distr/src/main/assembly/bin.xml
@@ -28,20 +28,16 @@
   
     <includeBaseDirectory>true</includeBaseDirectory>
 	<baseDirectory>/apache-opennlp-${project.version}</baseDirectory>
-  
+	
 	<dependencySets>
 		<dependencySet>
-			<includes>
-				<include>org.apache.opennlp:opennlp-tools</include>
-				<include>org.apache.opennlp:opennlp-uima</include>
-				<include>org.apache.opennlp:opennlp-brat-annotator</include>
-				<include>org.apache.opennlp:opennlp-morfologik-addon</include>
-			</includes>
+			<scope>runtime</scope>
 			<unpack>false</unpack>
 			<useProjectArtifact>false</useProjectArtifact>
 			<fileMode>644</fileMode>
 			<directoryMode>755</directoryMode>
 			<outputDirectory>lib</outputDirectory>
+			<useTransitiveDependencies>true</useTransitiveDependencies>
 		</dependencySet>
 	</dependencySets>
 	


[2/3] opennlp git commit: The distributions should include launchers for Brat and Morfologik

Posted by co...@apache.org.
The distributions should include launchers for Brat and Morfologik

Added launcher scripts to make it easy to execute the Brat and Morfologik add-on from command line.

See issue OPENNLP-895


Project: http://git-wip-us.apache.org/repos/asf/opennlp/repo
Commit: http://git-wip-us.apache.org/repos/asf/opennlp/commit/30eb9d98
Tree: http://git-wip-us.apache.org/repos/asf/opennlp/tree/30eb9d98
Diff: http://git-wip-us.apache.org/repos/asf/opennlp/diff/30eb9d98

Branch: refs/heads/trunk
Commit: 30eb9d98ee111eab9e1418292bfa3e52faca953f
Parents: 8d0d532
Author: William Colen <co...@apache.org>
Authored: Mon Dec 26 15:54:03 2016 -0200
Committer: William Colen <co...@apache.org>
Committed: Mon Dec 26 15:54:03 2016 -0200

----------------------------------------------------------------------
 .../src/main/bin/brat-annotation-service        | 35 +++++++++++++++
 .../src/main/bin/brat-annotation-service.bat    | 47 ++++++++++++++++++++
 opennlp-distr/src/main/assembly/bin.xml         | 14 ++++++
 .../src/main/bin/opennlp-cp                     | 35 ---------------
 4 files changed, 96 insertions(+), 35 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/opennlp/blob/30eb9d98/opennlp-brat-annotator/src/main/bin/brat-annotation-service
----------------------------------------------------------------------
diff --git a/opennlp-brat-annotator/src/main/bin/brat-annotation-service b/opennlp-brat-annotator/src/main/bin/brat-annotation-service
new file mode 100755
index 0000000..4b0094a
--- /dev/null
+++ b/opennlp-brat-annotator/src/main/bin/brat-annotation-service
@@ -0,0 +1,35 @@
+#!/bin/sh
+
+#   Licensed to the Apache Software Foundation (ASF) under one
+#   or more contributor license agreements.  See the NOTICE file
+#   distributed with this work for additional information
+#   regarding copyright ownership.  The ASF licenses this file
+#   to you under the Apache License, Version 2.0 (the
+#   "License"); you may not use this file except in compliance
+#   with the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+#   Unless required by applicable law or agreed to in writing,
+#   software distributed under the License is distributed on an
+#   #  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#   KIND, either express or implied.  See the License for the
+#   specific language governing permissions and limitations
+#   under the License.
+
+# Note:  Do not output anything in this script file, any output
+#        may be inadvertantly placed in any output files if
+#        output redirection is used.
+
+if [ -z "$JAVACMD" ] ; then
+  if [ -n "$JAVA_HOME"  ] ; then
+    JAVACMD="$JAVA_HOME/bin/java"
+  else
+    JAVACMD="`which java`"
+  fi
+fi
+
+# Might fail if $0 is a link
+OPENNLP_HOME=`dirname "$0"`/..
+
+$JAVACMD -Xmx1024m -cp "lib/*" opennlp.bratann.NameFinderAnnService $@

http://git-wip-us.apache.org/repos/asf/opennlp/blob/30eb9d98/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat
----------------------------------------------------------------------
diff --git a/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat b/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat
new file mode 100755
index 0000000..06a626a
--- /dev/null
+++ b/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat
@@ -0,0 +1,47 @@
+@ECHO off
+
+REM #   Licensed to the Apache Software Foundation (ASF) under one
+REM #   or more contributor license agreements.  See the NOTICE file
+REM #   distributed with this work for additional information
+REM #   regarding copyright ownership.  The ASF licenses this file
+REM #   to you under the Apache License, Version 2.0 (the
+REM #   "License"); you may not use this file except in compliance
+REM #   with the License.  You may obtain a copy of the License at
+REM #
+REM #    http://www.apache.org/licenses/LICENSE-2.0
+REM #
+REM #   Unless required by applicable law or agreed to in writing,
+REM #   software distributed under the License is distributed on an
+REM #   #  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+REM #   KIND, either express or implied.  See the License for the
+REM #   specific language governing permissions and limitations
+REM #   under the License.
+
+REM # Note:  Do not output anything in this script file, any output
+REM #        may be inadvertantly placed in any output files if
+REM #        output redirection is used.
+SETLOCAL
+
+IF "%JAVA_CMD%" == "" (
+	IF "%JAVA_HOME%" == "" (
+		SET JAVA_CMD=java 
+	) ELSE (
+		REM # Keep JAVA_HOME to short-name without spaces
+		FOR %%A IN ("%JAVA_HOME%") DO SET JAVA_CMD=%%~sfA\bin\java
+	)
+)
+
+REM #  Should work with Windows XP and greater.  If not, specify the path to where it is installed.
+IF "%OPENNLP_HOME%" == "" (
+	SET OPENNLP_HOME=%~sp0..
+) ELSE (
+	REM # Keep OPENNLP_HOME to short-name without spaces
+	FOR %%A IN ("%OPENNLP_HOME%") DO SET OPENNLP_HOME=%%~sfA
+)
+
+REM #  Get the library JAR file name (JIRA OPENNLP-554)
+FOR %%A IN ("%OPENNLP_HOME%\lib\*.jar") DO SET JAR_FILE=%%A
+
+%JAVA_CMD% -Xmx1024m -jar %JAR_FILE% opennlp.bratann.NameFinderAnnService %*
+
+ENDLOCAL
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/opennlp/blob/30eb9d98/opennlp-distr/src/main/assembly/bin.xml
----------------------------------------------------------------------
diff --git a/opennlp-distr/src/main/assembly/bin.xml b/opennlp-distr/src/main/assembly/bin.xml
index 4ed17f8..615c7fc 100644
--- a/opennlp-distr/src/main/assembly/bin.xml
+++ b/opennlp-distr/src/main/assembly/bin.xml
@@ -74,6 +74,20 @@
 			<directoryMode>755</directoryMode>
 			<outputDirectory>bin</outputDirectory>
 		</fileSet>
+
+		<fileSet>
+			<directory>../opennlp-morfologik-addon/src/main/bin</directory>
+			<fileMode>755</fileMode>
+			<directoryMode>755</directoryMode>
+			<outputDirectory>bin</outputDirectory>
+		</fileSet>
+		
+		<fileSet>
+			<directory>../opennlp-brat-annotator/src/main/bin</directory>
+			<fileMode>755</fileMode>
+			<directoryMode>755</directoryMode>
+			<outputDirectory>bin</outputDirectory>
+		</fileSet>
 		
 		<fileSet>
 			<directory>../opennlp-docs/target/docbkx/html</directory>

http://git-wip-us.apache.org/repos/asf/opennlp/blob/30eb9d98/opennlp-morfologik-addon/src/main/bin/opennlp-cp
----------------------------------------------------------------------
diff --git a/opennlp-morfologik-addon/src/main/bin/opennlp-cp b/opennlp-morfologik-addon/src/main/bin/opennlp-cp
deleted file mode 100755
index dff0d12..0000000
--- a/opennlp-morfologik-addon/src/main/bin/opennlp-cp
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/bin/sh
-
-#   Licensed to the Apache Software Foundation (ASF) under one
-#   or more contributor license agreements.  See the NOTICE file
-#   distributed with this work for additional information
-#   regarding copyright ownership.  The ASF licenses this file
-#   to you under the Apache License, Version 2.0 (the
-#   "License"); you may not use this file except in compliance
-#   with the License.  You may obtain a copy of the License at
-#
-#    http://www.apache.org/licenses/LICENSE-2.0
-#
-#   Unless required by applicable law or agreed to in writing,
-#   software distributed under the License is distributed on an
-#   #  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-#   KIND, either express or implied.  See the License for the
-#   specific language governing permissions and limitations
-#   under the License.
-
-# Note:  Do not output anything in this script file, any output
-#        may be inadvertantly placed in any output files if
-#        output redirection is used.
-
-if [ -z "$JAVACMD" ] ; then
-  if [ -n "$JAVA_HOME"  ] ; then
-    JAVACMD="$JAVA_HOME/bin/java"
-  else
-    JAVACMD="`which java`"
-  fi
-fi
-
-# Might fail if $0 is a link
-OPENNLP_HOME=`dirname "$0"`/..
-
-$JAVACMD -Xmx1024m -cp "lib/*" opennlp.tools.cmdline.CLI $@


[3/3] opennlp git commit: Fix the Brat and Morfologik .bat launchers

Posted by co...@apache.org.
Fix the Brat and Morfologik .bat launchers

Fixed the .bat scripts that launches brat and morfologik CLI.

See issue OPENNLP-895


Project: http://git-wip-us.apache.org/repos/asf/opennlp/repo
Commit: http://git-wip-us.apache.org/repos/asf/opennlp/commit/b1218790
Tree: http://git-wip-us.apache.org/repos/asf/opennlp/tree/b1218790
Diff: http://git-wip-us.apache.org/repos/asf/opennlp/diff/b1218790

Branch: refs/heads/trunk
Commit: b12187901442f51f18ea5582ae53bf9b973f09b0
Parents: 30eb9d9
Author: William Colen <co...@apache.org>
Authored: Tue Dec 27 00:58:49 2016 -0200
Committer: William Colen <co...@apache.org>
Committed: Tue Dec 27 00:58:49 2016 -0200

----------------------------------------------------------------------
 .../src/main/bin/brat-annotation-service.bat              | 10 +++++++---
 .../src/main/bin/morfologik-addon.bat                     | 10 +++++++---
 2 files changed, 14 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/opennlp/blob/b1218790/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat
----------------------------------------------------------------------
diff --git a/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat b/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat
index 06a626a..1db08a7 100755
--- a/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat
+++ b/opennlp-brat-annotator/src/main/bin/brat-annotation-service.bat
@@ -38,10 +38,14 @@ IF "%OPENNLP_HOME%" == "" (
 	REM # Keep OPENNLP_HOME to short-name without spaces
 	FOR %%A IN ("%OPENNLP_HOME%") DO SET OPENNLP_HOME=%%~sfA
 )
+setLocal EnableDelayedExpansion
+set CLASSPATH="
 
-REM #  Get the library JAR file name (JIRA OPENNLP-554)
-FOR %%A IN ("%OPENNLP_HOME%\lib\*.jar") DO SET JAR_FILE=%%A
+FOR %%A IN ("%OPENNLP_HOME%\lib\*.jar") DO (
+	set CLASSPATH=!CLASSPATH!;%%A
+)
+set CLASSPATH=!CLASSPATH!"
 
-%JAVA_CMD% -Xmx1024m -jar %JAR_FILE% opennlp.bratann.NameFinderAnnService %*
+%JAVA_CMD% -Xmx1024m -cp %CLASSPATH% opennlp.bratann.NameFinderAnnService %*
 
 ENDLOCAL
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/opennlp/blob/b1218790/opennlp-morfologik-addon/src/main/bin/morfologik-addon.bat
----------------------------------------------------------------------
diff --git a/opennlp-morfologik-addon/src/main/bin/morfologik-addon.bat b/opennlp-morfologik-addon/src/main/bin/morfologik-addon.bat
index aeec31f..79833c0 100644
--- a/opennlp-morfologik-addon/src/main/bin/morfologik-addon.bat
+++ b/opennlp-morfologik-addon/src/main/bin/morfologik-addon.bat
@@ -38,10 +38,14 @@ IF "%OPENNLP_HOME%" == "" (
 	REM # Keep OPENNLP_HOME to short-name without spaces
 	FOR %%A IN ("%OPENNLP_HOME%") DO SET OPENNLP_HOME=%%~sfA
 )
+setLocal EnableDelayedExpansion
+set CLASSPATH="
 
-REM #  Get the library JAR file name (JIRA OPENNLP-554)
-FOR %%A IN ("%OPENNLP_HOME%\lib\*.jar") DO SET JAR_FILE=%%A
+FOR %%A IN ("%OPENNLP_HOME%\lib\*.jar") DO (
+	set CLASSPATH=!CLASSPATH!;%%A
+)
+set CLASSPATH=!CLASSPATH!"
 
-%JAVA_CMD% -Xmx1024m -jar %JAR_FILE% %*
+%JAVA_CMD% -Xmx1024m -cp %CLASSPATH% opennlp.morfologik.cmdline.CLI %*
 
 ENDLOCAL
\ No newline at end of file