Em 20-05-2011 14:18, Stéphane Ducasse escreveu:
> ah tradition are so good.
> May be we should have a cron job for these topics :)
>
> Stef
(...)
Yeah. Let's assume something like that:

    #/bin/bash

    if [ $# -lt 2 ]
    then
      echo $0 "Wrong number of parameters. Plz, specify rant/bragging"
    else
      /usr/local/bin/restartOldDiscussion -topic $1 &
      PID=$!
      if [ $PID != "" ]
      then
        sleep `expr 3600 \* 24 \* 5`
        kill -KILL $PID
      fi
    fi


That would limit "periodic discussions" to 5 days (top)...
(sorry, couldn't resist)

Reply via email to