Skip to content

Instantly share code, notes, and snippets.

@heydamianc
Created November 12, 2011 15:37
Show Gist options
  • Save heydamianc/1360700 to your computer and use it in GitHub Desktop.
Save heydamianc/1360700 to your computer and use it in GitHub Desktop.
Appengine debug script
#!/bin/bash
#
# Launches the development AppServer
#
# Usage:
# ./debug.sh --port=8888 ~/Development/Project/target/Project-SNAPSHOT
[ -z "${DEBUG}" ] || set -x # trace if $DEBUG env. var. is non-zero
SDK_BIN=`dirname $0 | sed -e "s#^\\([^/]\\)#${PWD}/\\1#"` # sed makes absolute
SDK_LIB=$SDK_BIN/../lib
SDK_CONFIG=$SDK_BIN/../config/sdk
java -ea -cp "$SDK_LIB/appengine-tools-api.jar" \
com.google.appengine.tools.KickStart \
--jvm_flag=-Xdebug \
--jvm_flag=-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=1044 \
com.google.appengine.tools.development.DevAppServerMain $*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment