Public feed #893121

Unnamed

public text v1 · immutable
Raw Edit
·published 2008-02-05 22:09 UTC
rendered paste body
alias ftprushsearch {
  rushsitexml
  .dll " $+ $scriptdirWhileFix.dll $+ " WhileFix
  var %i = 1
  ; delay wait before new site
  var %delay = 2
  window -w @search
  clear @search
  while (%i <= $lines(rushsite.xml)) {

    if (*<SITE*NAME="* iswm $read(%rushsitexmlpath,%i)) {
      .timersearch $+ %i 1 %delay dosearch $gettok($read(%rushsitexmlpath,%i),2,34) $1-
      var %delay $calc(%delay + 2)
    }

    inc %i

  }
  echo @search Search sussesfully sent to all sites, done on $duration(%delay)
}

alias dosearch {
  dll rushmirc.dll EnableCallback
  dll rushmirc.dll SetMircCmd /aline @search
  dll Rushmirc.dll RushScript RushApp.FTP.RAW(' $+ $1 $+ ','site search $2-',RS_LOGIN or RS_LOGOUT);
}

alias rushsitexml {
  if (%rushsitexmlpath == $null) || (!$exists(%rushsitexmlpath)) {
    %rushsitexmlpath = $sdir="Select the Directory Containing rushsite.xml" C:\
    set %rushsitexmlpath " $+ %rushsitexmlpath $+ rushsite.xml $+ "
    if ($exists(%rushsitexmlpath)) { set %rushsitexmlpath %rushsitexmlpath }
    if (!$exists(%rushsitexmlpath)) { echo 4 -a Maybe you should try again? there is no rushsite.xml | unset %rushsitexmlpath | halt }
  }
}