home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 206.lha / Flist_v1.2 / Sources / fl.flex < prev    next >
Text File  |  1988-12-28  |  2KB  |  82 lines

  1. /* 
  2.     This is a test rexx macro prog for Flist!
  3.  
  4.     Here we test message passing between rexx and Flist. 
  5.  
  6.     NOTE: all commands that exist on their own lines and inclosed in 
  7.     single quotes (optional) are passed to flist.
  8.  
  9.     Written by Stephen (Raz) Berry
  10. */
  11.  
  12. trace off
  13.  
  14. address "flport"    /* Flist's port name */
  15.  
  16. norm = '9b34303b33316d'X    /* screen colors for highlights */
  17. rever = '9b34303b33336d'X
  18.  
  19. if ~open(fd,'CON:0/80/640/30/Rexx_test') then exit(-30)
  20. dummy = writeln(fd,rever || '  Prepare for Iconification!')
  21. address command 'wait 3 sec'
  22. dummy = close(fd)
  23.  
  24.  'iconify'  /* use Leo's iconify prog to shrink flist to an icon */
  25.  
  26. if ~open(fd,'CON:0/80/640/40/Rexx_test') then exit(-30)
  27. dummy = writeln(fd,' This is what happens when you send a bad command.')
  28. address command 'wait 3 sec'
  29.  
  30.  this is crapola  /* show what happens when a bad command is sent */
  31.  
  32. dummy = writeln(fd,'  Now we will sort the list by their file sizes!')
  33. address command 'wait 3 sec'
  34.  
  35.  sort z   /* sort the list by size */
  36.  
  37. dummy = writeln(fd,'Now let us make a trip to the parent of this directory.')
  38. address command 'wait 3 sec'
  39.  
  40.  parent   /* get the parent dir */
  41.  
  42. dummy = writeln(fd,'Pretend you have made a change to this directory.')
  43. address command 'wait 2 sec'
  44.  
  45. dummy = writeln(fd,'Very Good. Now we can make Flist aware of the change.')
  46. address command 'wait 2 sec'
  47.  
  48.  reget    /* reload the dir */
  49.  
  50. dummy = writeln(fd,'Now lets show off the pattern sorting ability of Flist.')
  51. address command 'wait 2 sec'
  52.  
  53.  sort o
  54.  
  55. dummy = writeln(fd,'Like that? Now we will make a new directory.')
  56. dummy = writeln(fd,'(Or you can hit return on a blank line to cancel)')
  57. address command 'wait 2 sec'
  58.  
  59.  makedir
  60.  
  61. dummy = writeln(fd,'Assuming you are executing this macro from the flist')
  62. dummy = writeln(fd,'directory we will change back to it now.')
  63. address command 'wait 2 sec'
  64.  
  65.  changedir Flist
  66.  
  67. dummy = writeln(fd,'Now if you like you can use the ARP filerequestor to go')
  68. dummy = writeln(fd,'to any volume your desire!')
  69. address command 'wait 2 sec'
  70.  
  71.  request
  72.  
  73. dummy = writeln(fd,rever || '  Thats all Folks!')
  74. address command 'wait 3 sec'
  75. dummy = close(fd)
  76.  
  77. /* use the quotes here because END is a REXX keyword also */
  78.  
  79.  'end'      /* this should end the comunication, ...this is real helpful! */
  80.  
  81. exit
  82.