home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 15 / AACD15.ISO / CDTools / S / AAGoFetch < prev    next >
Text File  |  2000-02-25  |  1KB  |  46 lines

  1. /*
  2.     $VER: AAGoFetch.br 1.1 (4.1.00)
  3.     by Neil Bothwick
  4.  
  5.     AAGoFetch is used by the AACD SearchCDs program to add found files
  6.     to the GoFetch! download queue. It requires the GOFETCH environment
  7.     variable as created by the GoFetch! installer.
  8. */
  9.  
  10. AminetServer = 'de.aminet.net'      /* You can set this to use one of the Aminet mirrors instead of the main site */
  11.  
  12. /* Do not change anything below here */
  13.  
  14. address command
  15. options results
  16. parse arg URL
  17. call addlib('rexxsupport.library',0,-30,0)
  18. call addlib('rexxdossupport.library',0,-30,0)
  19.  
  20. /* Load GoFetch! if not already running */
  21. if ~show('P','GOFETCH') then do
  22.     GFPath = GetVar('GOFETCH')
  23.     if GFPath = '' then do
  24.         'RequestChoice >NIL: "Amiga Active CD" "You need to install GoFetch*Nfor this function to work" "OK"'
  25.         exit
  26.         end
  27.     GFPath = AddPart(GFPath,'GoFetch!')
  28.     end
  29.  
  30. if ~show('P','GOFETCH') then do
  31.     'run >NIL:' GFPath
  32.     do i = 1 to 6 until RC = 0
  33.         'waitforport GOFETCH'
  34.         end
  35.     address 'GOFETCH' 'iconify'
  36.     end
  37.  
  38. /* Create download profile */
  39. address 'GOFETCH'
  40. 'getdownloadpath'
  41. DownloadDir = result
  42. parse var URL . '://' Server '/' Path
  43. 'addanonprofile site' Server 'port 21 remotepath' PathPart(Path) 'filename' FilePart(Path) 'downloaddir' DownloadDir
  44.  
  45.  
  46.