Permalink
Browse files

Changing how we create the CLASSPATH to play friendlier with our new …

…package layout.
  • Loading branch information...
1 parent 05e02dd commit 3eb06a5dd5c9eb69dc8f237a63d6799b18cc8854 @sbisbee sbisbee committed Sep 28, 2010
Showing with 5 additions and 11 deletions.
  1. +5 −11 src/main/bin/couchdb-lucene
@@ -33,16 +33,10 @@ getPid()
start()
{
- JAVA_OPTS="-server -Xmx1g"
- CLASS="com.github.rnewson.couchdb.lucene.Main"
+ CLASSPATH="$CL_BASEDIR/etc/couchdb-lucene:$CL_BASEDIR/lib/couchdb-lucene/*"
+ JAVA_OPTS="-server -Xmx1g -cp $CLASSPATH"
- CLASSPATH="conf"
- for JAR in `ls lib/*.jar`
- do
- CLASSPATH="$CLASSPATH:$JAR"
- done
-
- command="java $JAVA_OPTS -cp $CLASSPATH $CLASS"
+ command="java $JAVA_OPTS $JAR com.github.rnewson.couchdb.lucene.Main"
if [ "$BACKGROUND" != "true" ]
then
@@ -89,8 +83,8 @@ parseOptions()
parseOptions $@
checkEnvironment
-[ -z $CL_BASEDIR ] && CL_BASEDIR=`dirname "$0"`
-cd $CL_BASEDIR/..
+[ -z $CL_BASEDIR ] && CL_BASEDIR=`dirname "$0"`"/.."
+cd $CL_BASEDIR
start

0 comments on commit 3eb06a5

Please sign in to comment.