#!/bin/sh 

LC_CTYPE=iso_8859_1
export LC_CTYPE

# JAVA_HOME=...
JAVA=$JAVA_HOME/bin/java

DIRLIBS=lib/*.jar
for i in ${DIRLIBS}
do
    # if the directory is empty, then it will return the input string
    # this is stupid, so case for it
    if [ "$i" != "${DIRLIBS}" ] ; then
      if [ -z "$LOCAL_CLASSPATH" ] ; then
        LOCAL_CLASSPATH=$i
      else
        LOCAL_CLASSPATH="$i":$LOCAL_CLASSPATH
      fi
    fi
done

$JAVA -Xmx128m -classpath ./bin:$CLASSPATH:$LOCAL_CLASSPATH com.hammurapi.render.emf.EcoreDoc $*
