Messages revision c17bbcd502afbae7853d791a028cd863b736f469
486N/A# Supported Environment Variables: 486N/A# - OPENGROK_STANDARD_ENV Run Time Shell Environment (Shell Script) 486N/A# - OPENGROK_CONFIGURATION User Configuration (Shell Script) 486N/A# Supported Environment Variables for configuring the default setup: 486N/A# - OPENGROK_DISTRIBUTION_BASE Base Directory of the OpenGrok Distribution 486N/A# - OPENGROK_JAR OpenGrok java package 486N/A# - DATE GNU date binary (supporting --date switch) 486N/A# - JAVA_HOME Full Path to Java Installation Root 486N/A# - JAVA Full Path to java binary (to enable 64bit JDK) 486N/A# - JAVA_OPTS Java options (e.g. for JVM memory increase view 619N/A echo "Usage: ${PROGNAME} [options] <text>" 3488N/A echo " -e|--expire human readable date string of expiration (default +5 min) (*)" 619N/A echo " --expire-timestamp explicit UTC timestamp for expiration in sec" 619N/A echo " -c|--class css class to apply for the message (default info)" 619N/A echo " -p|--port remote port number of the application (default 2424)" 619N/A echo " -s|--server remote server of the application (default localhost)" 619N/A echo " --type type of the message (default normal)" 486N/A echo " (*) see man date: option --date (requires GNU date - use DATE env variable)" 486N/A echo " css classes: success, info, warning, error" 486N/A echo " types: normal, abort" 486N/A echo " tags: main, <project name>" 486N/A echo " text: supports html markup" 486N/A echo " Optional environment variables:" 486N/A echo " OPENGROK_CONFIGURATION - location of your configuration" 2976N/A echo " See the code for more information on configuration options /" \ 2296N/A echo "Argument \"$1\" expects a value" 2402N/A echo "Configuration loaded" # Find and load relevant configuration # Taken (and modified) from original OpenGrok shell wrapper if [ -f "${OPENGROK_STANDARD_ENV}" ] Progress "Loading ${OPENGROK_STANDARD_ENV} ..." . "${OPENGROK_STANDARD_ENV}" if [ -n "${OPENGROK_CONFIGURATION}" -a -f "${OPENGROK_CONFIGURATION}" ] # Load the Local OpenGrok Configuration Environment Progress "Loading ${OPENGROK_CONFIGURATION} ..." . "${OPENGROK_CONFIGURATION}" if [ -z "${OPENGROK_DISTRIBUTION_BASE}" ] if [ -d "${SCRIPT_DIRECTORY}/../dist" -a \ # Handle Developer Build Environments # Handle Binary Distributions # REQUIRED: Java Virtual Machine # REQUIRED: OpenGrok library # Find java home based on your system information # Taken from original OpenGrok shell wrapper echo "Cannot determine operating system version" case "${OS_NAME}:${OS_VERSION}" in echo "Unable to determine Java Home" \ "for ${OS_NAME} ${OS_VERSION}" if [ ! -d "${javaHome}" ] echo "Missing Java Home ${javaHome}" echo "Bad syntax. Expecting some arguments." echo "Maybe try --help option?" echo "Uknown option \"$opt\"" &&
Usage &&
exit 5 echo "Bad syntax. The text should be the last argument." echo "Stopped near \"$@\"." echo "Check the quotes around the arguments?" break # exit the while cycle echo "Bad syntax. The text must be specified only once." [ -z
"$MESSAGE_TEXT" ] &&
echo "The text of the message must be specified" &&
Usage &&
exit 3 echo "Consider installing gnu date and setting env variable DATE."