Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance
Java decentralizedintranet-searchintranet-search-enginep2pp2p-networkprivacyprivacy-protectionsearch-enginesearchenginewebweb-search-enginewebsearchwebseearch-engine
further cleanup
allofda7031991c8
diff --git a/startYACY.sh b/startYACY.shindex 9b5e86d27..4561fde80 100755--- a/startYACY.sh+++ b/startYACY.sh@@ -1,36 +1,26 @@#!/bin/sh-if [ `id -u` -eq 0 ]+JAVA="`which java`"+LOGFILE="yacy.log"+if [ "`id -u`" -eq 0 ]thenechoecho "For security reasons you should not run this script as root!"echoexit 1-elif [ ! -x "`which java`" ]+elif [ ! -x "$JAVA" ]thenecho "The java command is not executable."echo "Either you have not installed java or it is not in your PATH"- #echo "Has this script been invoked by CRON? Then use the -c option."+ #Cron supports setting the path in+ #echo "Has this script been invoked by CRON?"+ #echo "if so, please set PATH in the crontab, or set the correct path in the variable in this script."exit 1fi--#-c to be imlemented.-#Possible locations for setting of PATH--#sh, ksh, bash, zsh-#. ~/.profile-#bash-#. ~/.bash_profile-#csh, tcsh-#. ~/.login-#sh, ksh, bash, zsh-#. /etc/profile-#csh, tcsh-#. /etc/csh.login#startup YaCy-cd `dirname $0`+cd "`dirname $0`"-options=$(getopt -n YaCy -o d,l,p -- $@)+options="`getopt -n YaCy -o d,l,p -- $@`"if [ $? -ne 0 ];thenexit 1;fi@@ -43,7 +33,7 @@ DEBUG=0PRINTONLY=0for option in $options;doif [ $isparameter -ne 1 ];then #option- if [ x$option = "x-l" ];then+ if [ "$option" = "-l" ];thenLOGGING=1if [ $DEBUG -eq 1 ];thenecho "can not combine -l and -d"@@ -68,13 +58,13 @@ for option in $options;dofi #parameter or option?done-#echo $options;exit 0 #debug for getopts+#echo $options;exit 0 #DEBUG for getopts#get javastart argsjava_args=""if [ -f DATA/SETTINGS/httpProxy.conf ]then- for i in $(grep javastart DATA/SETTINGS/httpProxy.conf);do+ for i in `grep javastart DATA/SETTINGS/httpProxy.conf`;doi="${i#javastart_*=}";JAVA_ARGS="-$i $JAVA_ARGS";done@@ -82,12 +72,6 @@ fi# generating the proper classpathCLASSPATH=""-#prefix=$(dirname $0);-#if [ x$prefix = "x." ];then-# prefix="";-#else-# prefix="$prefix/"-#fifor N in lib/*.jar; do CLASSPATH="$CLASSPATH$N:"; donefor N in libx/*.jar; do CLASSPATH="$CLASSPATH$N:"; doneCLASSPATH="classes:.:$CLASSPATH"@@ -96,30 +80,22 @@ CLASSPATH="classes:.:$CLASSPATH"cmdline="";if [ $DEBUG -eq 1 ] #debugthen- if [ $PRINTONLY -eq 1 ];then- echo java $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy- else- java $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy- fi+ cmdline="$JAVA $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy"elif [ $LOGGING -eq 1 ];then #logging- if [ $PRINTONLY -eq 1 ];then- echo "java $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy >> yacy.log"- else- nohup java $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy >> yacy.log &- fi+ cmdline="$JAVA $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy >> yacy.log &"+else+ cmdline="$JAVA $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy > /dev/null &"+fi+if [ $PRINTONLY -eq 1 ];then+ echo $cmdlineelse- if [ $PRINTONLY -eq 1 ];then- echo "java $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy > /dev/null"- else- nohup java $JAVA_ARGS -Djava.awt.headless=true -classpath $CLASSPATH yacy > /dev/null &- #nohup java -Xms160m -Xmx160m -classpath $CLASSPATH yacy > /dev/null &- echo "****************** YaCy Web Crawler/Indexer & Search Engine *******************"- echo "**** (C) by Michael Peter Christen, usage granted under the GPL Version 2 ****"- echo "**** USE AT YOUR OWN RISK! Project home and releases: http://yacy.net/yacy ****"- echo "** LOG of YaCy: DATA/LOG/yacy00.log (and yacy<xx>.log) **"- echo "** STOP YaCy: execute stopYACY.sh and wait some seconds **"- echo "** GET HELP for YaCy: see www.yacy-websearch.net/wiki and www.yacy-forum.de **"- echo "*******************************************************************************"- echo " >> YaCy started as daemon process. Administration at http://localhost:8080 <<"- fi+ echo "****************** YaCy Web Crawler/Indexer & Search Engine *******************"+ echo "**** (C) by Michael Peter Christen, usage granted under the GPL Version 2 ****"+ echo "**** USE AT YOUR OWN RISK! Project home and releases: http://yacy.net/yacy ****"+ echo "** LOG of YaCy: DATA/LOG/yacy00.log (and yacy<xx>.log) **"+ echo "** STOP YaCy: execute stopYACY.sh and wait some seconds **"+ echo "** GET HELP for YaCy: see www.yacy-websearch.net/wiki and www.yacy-forum.de **"+ echo "*******************************************************************************"+ echo " >> YaCy started as daemon process. Administration at http://localhost:8080 << "+ eval $cmdlinefi