From baa3dfc68a74fec68aed162230bd3b8e20f3eba9 Mon Sep 17 00:00:00 2001 From: Razvan Deaconescu Date: Fri, 6 Aug 2010 17:47:31 +0300 Subject: [PATCH] ControlScripts: add message output to hrk complete detection script --- ControlScripts/detect_complete_hrk.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ControlScripts/detect_complete_hrk.sh b/ControlScripts/detect_complete_hrk.sh index c8229d4..93dfaa7 100755 --- a/ControlScripts/detect_complete_hrk.sh +++ b/ControlScripts/detect_complete_hrk.sh @@ -28,12 +28,16 @@ LOG_FILE=$1 while true; do # check for complete transfer if cat $LOG_FILE | grep "Torrent finished" &> /dev/null; then + echo "Torrent transfer finished" exit 0 fi # check stat client is alive if ! pgrep "hrktorrent" &> /dev/null; then - exit 0 + if ! pgrep -f "schedule_client.sh" &> /dev/null; then + echo "No hrktorrent and no schedule_client.sh process" + exit 0 + fi fi # Don't do continuous polling -- 2.20.1