You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by vg...@apache.org on 2007/11/16 14:19:01 UTC

svn commit: r595653 - /cocoon/trunk/cocoon.sh

Author: vgritsenko
Date: Fri Nov 16 05:19:01 2007
New Revision: 595653

URL: http://svn.apache.org/viewvc?rev=595653&view=rev
Log:
add 'debug' parameter

Modified:
    cocoon/trunk/cocoon.sh

Modified: cocoon/trunk/cocoon.sh
URL: http://svn.apache.org/viewvc/cocoon/trunk/cocoon.sh?rev=595653&r1=595652&r2=595653&view=diff
==============================================================================
--- cocoon/trunk/cocoon.sh (original)
+++ cocoon/trunk/cocoon.sh Fri Nov 16 05:19:01 2007
@@ -1,5 +1,38 @@
 #!/bin/sh
 
-#export MAVEN_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,address=5005,server=y,suspend=n"
-cd core/cocoon-webapp && echo "Starting in `pwd`" && mvn -Djava.awt.headless=true -Dorg.apache.cocoon.mode=dev $* jetty:run
+# 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.
 
+CWD=`pwd`
+MAVEN_OPTS="$MAVEN_OPTS -Djava.awt.headless=true -Dorg.apache.cocoon.mode=dev"
+
+ARGS=""
+while [ "$#" -gt "0" ]
+do
+  case "$1" in
+    debug)
+      MAVEN_OPTS="-Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,address=5005,server=y,suspend=n $MAVEN_OPTS -Djava.compiler=NONE"
+      ;;
+    *)
+      ARGS="$ARGS $1"
+  esac
+
+  shift
+done
+
+export MAVEN_OPTS
+cd core/cocoon-webapp && echo "Starting in `pwd`" && mvn jetty:run
+
+cd $CWD