Feature #727

transfer

Added by Ammler over 10 years ago. Updated over 10 years ago.

Status:ClosedStart date:2010-01-28
Priority:NormalDue date:
Assignee:Osai% Done:

100%

Category:-Estimated time:0.20 hour
Target version:-

Description

custom command:

if {![::mod_irc::nickIsOp [who]]} {
        say::public "you must be channel op to use [command]" 
} elseif { [numArgs] == 3 || [numArgs] == 4 } {
#       say::reply "So: [numArgs]" 
        if { [numArgs] == 3 } {
                catch { exec ~/script/transfer.sh public [getArg 1] /home/openttd/website/public/save/[getArg 2] } data
        } else {
                catch { exec ~/script/transfer.sh public [getArg 1] [getArg 2] /home/openttd/website/public/save/[getArg 3] } data
        }
#       say::reply $msg
        ::mod_irc::say::more::clear [who]
        foreach line [split $data "\n"] {
#                if {[string trim $line] != {} && [string first {-} $line] == 0 && [string first {--} $line] == -1} {
                        ::mod_irc::say::more::add [who] $line
#                }
        }
        ::mod_irc::say::more::sendNext [who] {} [private]

} else {
        say::reply "[command] gamenr save: transfer the save to our web" 
}

bash script: http://ps.openttdcoop.org/transfer.sh.txt

History

#1 Updated by Osai over 10 years ago

  • Assignee set to Osai

#2 Updated by Osai over 10 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100
  • Estimated time set to 0.20

added in r3

Also available in: Atom PDF