You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by an...@apache.org on 2012/02/24 12:18:22 UTC

svn commit: r1293179 - in /incubator/jena/Jena2/TDB/trunk/bin: make_classpath tdb tdb_cmd tdb_init tdb_path tdbbackup tdbclean tdbdump tdbloader tdbloader2 tdbquery tdbrecovery tdbstats tdbupdate tdbverify

Author: andy
Date: Fri Feb 24 11:18:21 2012
New Revision: 1293179

URL: http://svn.apache.org/viewvc?rev=1293179&view=rev
Log:
Cleanup scripts.

Removed:
    incubator/jena/Jena2/TDB/trunk/bin/make_classpath
Modified:
    incubator/jena/Jena2/TDB/trunk/bin/tdb
    incubator/jena/Jena2/TDB/trunk/bin/tdb_cmd
    incubator/jena/Jena2/TDB/trunk/bin/tdb_init
    incubator/jena/Jena2/TDB/trunk/bin/tdb_path
    incubator/jena/Jena2/TDB/trunk/bin/tdbbackup
    incubator/jena/Jena2/TDB/trunk/bin/tdbclean
    incubator/jena/Jena2/TDB/trunk/bin/tdbdump
    incubator/jena/Jena2/TDB/trunk/bin/tdbloader
    incubator/jena/Jena2/TDB/trunk/bin/tdbloader2
    incubator/jena/Jena2/TDB/trunk/bin/tdbquery
    incubator/jena/Jena2/TDB/trunk/bin/tdbrecovery
    incubator/jena/Jena2/TDB/trunk/bin/tdbstats
    incubator/jena/Jena2/TDB/trunk/bin/tdbupdate
    incubator/jena/Jena2/TDB/trunk/bin/tdbverify

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdb
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdb?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdb (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdb Fri Feb 24 11:18:21 2012
@@ -1,13 +1,12 @@
-#!/bin/bash
-# Run something 
+#!/bin/sh
+# Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
 
+# Run something, setting the classpath for TDB code.
 if [ "$#" = 0 ]
 then
-    echo "Usage: $0 [VMargs] classname [args ...]"
+    echo "Usage: $0 classname [args ...]"
     exit 1
     fi
 
-source "$TDBROOT/bin/tdb_init"
-
-
+. "$TDBROOT/bin/tdb_init"
 exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdb_cmd
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdb_cmd?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdb_cmd (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdb_cmd Fri Feb 24 11:18:21 2012
@@ -1,4 +1,20 @@
-#!/bin/bash
+#!/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.
 
 if [ "$TDBROOT" = "" ]
     then 
@@ -9,11 +25,11 @@ fi
 INIT="$TDBROOT/bin/tdb_init"
 
 if [ ! -r "$INIT" ] 
-    then 
+then 
     echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
     exit 1
 fi
 
-source "$INIT"
+. "$INIT"
 #echo "$TDB_CP"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdb_init
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdb_init?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdb_init (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdb_init Fri Feb 24 11:18:21 2012
@@ -1,7 +1,9 @@
-#!/bin/bash 
+#!/bin/sh 
 #  -- hint to emacs
-# Source this file, not execute it.
 
+## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
+
+# Source this file, not execute it.
 ## Environment variable usage:
 ## TDBROOT         :: The root of the TDB installation (required)
 ## JVM_ARGS        :: Additional argument to the JVM (e.g. -Xmx1024M)
@@ -22,13 +24,6 @@ then
     exit 1
     fi
 
-## ---- Set class path separator 
-SEP=':'
-if [ "$OSTYPE" = "cygwin" ]
-then
-    SEP=';'
-    fi
-
 ## ---- who am I?
 TDB_CMD=$(basename $0)
 

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdb_path
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdb_path?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdb_path (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdb_path Fri Feb 24 11:18:21 2012
@@ -1,11 +1,46 @@
-#!/bin/bash
-# Sets CP
+#!/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.
 
 # Check for development system
-if [ ! -e "$TDBROOT/lib" ]
+if [ -e "$TDBROOT/lib" ]
 then
-    CP="$($TDBROOT/bin/make_classpath_mvn "$TDBROOT")"
-else
-    CP="$($TDBROOT/bin/make_classpath "$TDBROOT")"
+    CP="$TDBROOT/lib/"'*'
+    echo "$CP"
+    exit
 fi
+
+M2_REPO="${M2_REPO:-$HOME/.m2/repository}" ;
+# Looking in the POM would be better but it is very slow.
+X=$(perl -ne 'next unless /\spath="M2_REPO([^"]*)"/s ; print "$1","\n"' $TDBROOT/.classpath)
+
+CP="${CP:-}"
+SEP=':'
+for x in $X
+do
+    [ -z "$CP" ] || CP="${CP}${SEP}"
+    CP="$CP$M2_REPO$x"
+done
+
+if [ -e "$TDBROOT/classes" ]
+then
+    CP="$TDBROOT/classes:$CP"
+elif [ -e "$TDBROOT/target/classes" ]
+then
+    CP="$TDBROOT/target/classes:$CP"
+fi
+
 echo "$CP"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbbackup
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbbackup?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbbackup (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbbackup Fri Feb 24 11:18:21 2012
@@ -1,4 +1,35 @@
-#!/bin/bash
+#!/bin/sh
 
-source "$TDBROOT/bin/tdb_init"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+# 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.
+
+if [ "$TDBROOT" = "" ]
+    then 
+    echo "TDBROOT is not set" 1>&2
+    exit 1
+fi
+
+INIT="$TDBROOT/bin/tdb_init"
+
+if [ ! -r "$INIT" ] 
+then 
+    echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
+    exit 1
+fi
+
+. "$INIT"
+#echo "$TDB_CP"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbclean
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbclean?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbclean (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbclean Fri Feb 24 11:18:21 2012
@@ -1,9 +1,11 @@
-#!/bin/bash
+#!/bin/sh
+# Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
+
 # Clean a location (directory)
 
 DIR="$1"
 
-if [ "$#" -gt 1 -o -z "$DIR" -o "$DIR" == "-h" -o "$DIR" == "-h" ]
+if [ "$#" -gt 1 -o -z "$DIR" -o "$DIR" = "-h" -o "$DIR" = "-h" ]
 then
     echo "Usage: $(basename $0) DIRECTORY" 1>&2
     exit 0

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbdump
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbdump?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbdump (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbdump Fri Feb 24 11:18:21 2012
@@ -1,5 +1,35 @@
-#!/bin/bash
+#!/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.
 
-source "$TDBROOT/bin/tdb_init"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+if [ "$TDBROOT" = "" ]
+    then 
+    echo "TDBROOT is not set" 1>&2
+    exit 1
+fi
+
+INIT="$TDBROOT/bin/tdb_init"
+
+if [ ! -r "$INIT" ] 
+then 
+    echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
+    exit 1
+fi
+
+. "$INIT"
+#echo "$TDB_CP"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbloader
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbloader?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbloader (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbloader Fri Feb 24 11:18:21 2012
@@ -1,4 +1,35 @@
-#!/bin/bash
+#!/bin/sh
 
-source "$TDBROOT/bin/tdb_init"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+# 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.
+
+if [ "$TDBROOT" = "" ]
+    then 
+    echo "TDBROOT is not set" 1>&2
+    exit 1
+fi
+
+INIT="$TDBROOT/bin/tdb_init"
+
+if [ ! -r "$INIT" ] 
+then 
+    echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
+    exit 1
+fi
+
+. "$INIT"
+#echo "$TDB_CP"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbloader2
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbloader2?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbloader2 (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbloader2 Fri Feb 24 11:18:21 2012
@@ -1,12 +1,28 @@
 #!/bin/bash
 
+## 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.
+
 # Exit on error.
 set -e
 
 # Sort order is ASCII
 export LC_LOCALE="C"
 
-function log { echo " $(date $DATE)" "$@" ; }
+log() { echo " $(date $DATE)" "$@" ; }
 
 TMP=$$
 #DATE="+%Y-%m-%dT%H:%M:%S%:z"
@@ -53,7 +69,7 @@ java -Xmx1200M -cp "$CP" -server "$PKG".
 ## All files are writtern S P O / G S P O columns per row but in different sort orders.
 log "Index phase"
 
-function process_rows
+process_rows()
 {
     local KEYS="$1"
     local DATA="$2"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbquery
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbquery?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbquery (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbquery Fri Feb 24 11:18:21 2012
@@ -1,4 +1,35 @@
-#!/bin/bash
+#!/bin/sh
 
-source "$TDBROOT/bin/tdb_init"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+# 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.
+
+if [ "$TDBROOT" = "" ]
+    then 
+    echo "TDBROOT is not set" 1>&2
+    exit 1
+fi
+
+INIT="$TDBROOT/bin/tdb_init"
+
+if [ ! -r "$INIT" ] 
+then 
+    echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
+    exit 1
+fi
+
+. "$INIT"
+#echo "$TDB_CP"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbrecovery
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbrecovery?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbrecovery (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbrecovery Fri Feb 24 11:18:21 2012
@@ -1,4 +1,20 @@
-#!/bin/bash
+#!/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.
 
 if [ "$TDBROOT" = "" ]
     then 
@@ -9,11 +25,11 @@ fi
 INIT="$TDBROOT/bin/tdb_init"
 
 if [ ! -r "$INIT" ] 
-    then 
+then 
     echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
     exit 1
 fi
 
-source "$INIT"
+. "$INIT"
 #echo "$TDB_CP"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbstats
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbstats?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbstats (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbstats Fri Feb 24 11:18:21 2012
@@ -1,4 +1,35 @@
-#!/bin/bash
+#!/bin/sh
 
-source "$TDBROOT/bin/tdb_init"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+# 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.
+
+if [ "$TDBROOT" = "" ]
+    then 
+    echo "TDBROOT is not set" 1>&2
+    exit 1
+fi
+
+INIT="$TDBROOT/bin/tdb_init"
+
+if [ ! -r "$INIT" ] 
+then 
+    echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
+    exit 1
+fi
+
+. "$INIT"
+#echo "$TDB_CP"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbupdate
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbupdate?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbupdate (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbupdate Fri Feb 24 11:18:21 2012
@@ -1,4 +1,35 @@
-#!/bin/bash
+#!/bin/sh
 
-source "$TDBROOT/bin/tdb_init"
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+# 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.
+
+if [ "$TDBROOT" = "" ]
+    then 
+    echo "TDBROOT is not set" 1>&2
+    exit 1
+fi
+
+INIT="$TDBROOT/bin/tdb_init"
+
+if [ ! -r "$INIT" ] 
+then 
+    echo "Script $INIT (\$TDBROOT/bin/tdb_init) does not exist or is not readable"
+    exit 1
+fi
+
+. "$INIT"
+#echo "$TDB_CP"
+exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" $TDB_SPEC "$@"

Modified: incubator/jena/Jena2/TDB/trunk/bin/tdbverify
URL: http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/bin/tdbverify?rev=1293179&r1=1293178&r2=1293179&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/bin/tdbverify (original)
+++ incubator/jena/Jena2/TDB/trunk/bin/tdbverify Fri Feb 24 11:18:21 2012
@@ -1,25 +1,11 @@
 #!/bin/bash
-
-echo "tdbverify - not operational"
-exit 1
-
-if ! [ -e "testing" ] 
-then
-    echo "Not in the root of a TDB installation" 1>&2
-    exit 1
-    fi
-export TDBROOT=$PWD
+# Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
 
 source "$TDBROOT/bin/tdb_init"
 
-if true 
-then
-    echo "JAVA_HOME =  $JAVA_HOME"
-    echo "TDBROOT   =  $TDBROOT"
-    echo "JVM_ARGS  =  $JVM_ARGS"
-    echo "SOCKS     =  $SOCKS"
-    echo "TDB_CP    =  $TDB_CP"
-    echo "TDB_CMD   =  $TDB_CMD"
-    fi
-
-exec java $JVM_ARGS $SOCKS -cp "$TDB_CP" "tdb.$TDB_CMD" "$@"
+echo "JAVA_HOME =  $JAVA_HOME"
+echo "TDBROOT   =  $TDBROOT"
+echo "JVM_ARGS  =  $JVM_ARGS"
+echo "SOCKS     =  $SOCKS"
+echo "TDB_CMD   =  $TDB_CMD"
+echo "TDB_CP    =  $TDB_CP"