-t(aillog) option, to start monitoring the log after startup. So you see the log, but can stop viewing it with ctrl+c, without stopping yacy.

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@2697 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
allo 18 years ago
parent fda7031991
commit a723c2809d

@ -20,7 +20,7 @@ fi
#startup YaCy #startup YaCy
cd "`dirname $0`" cd "`dirname $0`"
options="`getopt -n YaCy -o d,l,p -- $@`" options="`getopt -n YaCy -o d,l,p,t -- $@`"
if [ $? -ne 0 ];then if [ $? -ne 0 ];then
exit 1; exit 1;
fi fi
@ -31,6 +31,7 @@ parameter="" #parameters will be collected here
LOGGING=0 LOGGING=0
DEBUG=0 DEBUG=0
PRINTONLY=0 PRINTONLY=0
TAILLOG=0
for option in $options;do for option in $options;do
if [ $isparameter -ne 1 ];then #option if [ $isparameter -ne 1 ];then #option
if [ "$option" = "-l" ];then if [ "$option" = "-l" ];then
@ -39,14 +40,16 @@ for option in $options;do
echo "can not combine -l and -d" echo "can not combine -l and -d"
exit 1; exit 1;
fi fi
elif [ x$option = "x-d" ];then elif [ "$option" = "-d" ];then
DEBUG=1 DEBUG=1
if [ $LOGGING -eq 1 ];then if [ $LOGGING -eq 1 ];then
echo "can not combine -l and -d" echo "can not combine -l and -d"
exit 1; exit 1;
fi fi
elif [ x$option = "x-p" ];then elif [ "$option" = "-p" ];then
PRINTONLY=1 PRINTONLY=1
elif [ "$option" = "-t" ];then
TAILLOG=1
fi #which option fi #which option
else #parameter else #parameter
if [ x$option = "--" ];then #option / parameter seperator if [ x$option = "--" ];then #option / parameter seperator
@ -98,4 +101,7 @@ else
echo "*******************************************************************************" echo "*******************************************************************************"
echo " >> YaCy started as daemon process. Administration at http://localhost:8080 << " echo " >> YaCy started as daemon process. Administration at http://localhost:8080 << "
eval $cmdline eval $cmdline
if [ "$TAILLOG" -eq "1" -a ! "$DEBUG" -eq "1" ];then
tail -f DATA/LOG/yacy00.log
fi
fi fi

Loading…
Cancel
Save