История изменений
Исправление makoven, (текущая версия) :
Костыли-костылёчки
#env !/bin/bash
PORT=8888
stop_thttpd(){
kill $HTTPID
ERRCODE=$?
if [ $ERRCODE -eq 0 ]; then
printf " Thttpd stopped\n"
else
printf "\nERROR\n"
fi
}
trap stop_thttpd INT
thttpd -D -p $PORT &
HTTPID=$!
printf "Server started at port $PORT with PID=$HTTPID\n"
wait $HTTPID
Исходная версия makoven, :
#env !/bin/bash
PORT=8888
stop_thttpd(){
kill $HTTPID
ERRCODE=$?
if [ $ERRCODE -eq 0 ]; then
printf " Thttpd stopped\n"
else
printf "\nERROR\n"
fi
}
trap stop_thttpd INT
thttpd -D -p $PORT &
HTTPID=$!
printf "Server started at port $PORT with PID=$HTTPID\n"
wait $HTTPID