- if(m.params =~ /^(\S+)\s+(?:about\s+)?(.*)\s+in\s+(.*)$/)
- who = $1
- subject = $2
- period = $3
- if(who =~ /^me$/)
- who = m.sourcenick
- else
- unless(m.plugin =~ /^remind\+$/)
- m.reply "incorrect usage: use remind+ to remind persons other than yourself"
- return
- end
- end
- if(err = add_reminder(who, subject, period))
- m.reply "incorrect usage: " + err
- return
- end
- elsif(m.params =~ /^(\S+)\s+(?:about\s+)?(.*)\s+every\s+(.*)$/)
- who = $1
- subject = $2
- period = $3
- if(who =~ /^me$/)
- who = m.sourcenick
- else
- unless(m.plugin =~ /^remind\+$/)
- m.reply "incorrect usage: use remind+ to remind persons other than yourself"
- return
- end
- end
- if(err = add_reminder(who, subject, period, true))
- m.reply "incorrect usage: " + err
- return
- end
- elsif(m.params =~ /^(\S+)\s+(?:about\s+)?(.*)\s+at\s+(.*)$/)
- who = $1
- subject = $2
- time = $3
- if(who =~ /^me$/)
- who = m.sourcenick
- else
- unless(m.plugin =~ /^remind\+$/)
- m.reply "incorrect usage: use remind+ to remind persons other than yourself"
- return
- end
- end
- if(err = add_reminder(who, subject, time))
- m.reply "incorrect usage: " + err
- return
+ begin
+ if !tried.include?(:in) and string =~ /^(.*)\s+in\s+(.*)$/
+ subject = $1
+ period = $2
+ tried << :in
+ add_reminder(m, who, subject, period)
+ return true