4 # avoid the crontab job for an hour
5 # wait until the running instance is done and create a void stamp
9 ls /git-mirror/LOCK >& /dev/null || {
10 touch /git-mirror/LOCK
11 echo "OK, git-mirror stopped for an hour"
19 if pgrep git-mirror >& /dev/null; then
20 echo "git-mirror instance is running"
28 pids=$(pgrep git-mirror)
29 if [ -n "$pids" ] ; then
30 echo "Active processes"
33 echo "No running instance of git-mirror"
35 echo "Lock file status"
36 ls -l /git-mirror/LOCK
40 totrash=$(ls /git-mirror/*/NOTIFIED 2> /dev/null)
41 if [ -z "$totrash" ] ; then
42 echo "No NOTIFIED file found"
44 echo "Trashing the following files"
57 *) echo "Usage: $COMMAND start|stop";;