home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Misc / EDGE1_704.DMS / in.adf / ExtraStuff / Edge_SasC.lha / rexx / hn_runproject.edge < prev   
Encoding:
Text File  |  1993-08-09  |  955 b   |  46 lines

  1. /* Edge macro: hn_runproject
  2. **
  3. ** $VER: hn_runproject.edge 1.4 (04-Mar-93 23:50:21)
  4. **
  5. ** Usage:    hn_runproject
  6. **
  7. ** Synopsis: Run selected project
  8. **           If you don't use SAS/C CPR then change DEBUGGER= to what ever
  9. **           debugger you prefer.
  10. **
  11. ** Author:   Henrik Nordström
  12. **           Ängsvägen 1
  13. **           S 756 45 Uppsala
  14. */
  15.  
  16. DEBUGGER='CPR'
  17.  
  18. parse arg mode
  19.  
  20. options results
  21.  
  22. 'getenvvar _fe_user9'
  23. parse var result projectdir ',' projectname ',' arguments
  24.  
  25. if projectname=="" then do
  26.     /* Get project name from path */
  27.     projectname=strip(projectdir,'T','/')
  28.     st=lastpos('/',projectname)
  29.     if st==0 then st=lastpos(':',projectname)
  30.     projectname=substr(projectname,st+1)
  31. end
  32.  
  33. call pragma('d',projectdir)
  34.  
  35. select 
  36. when mode='' | mode='RUN' then
  37.   address COMMAND projectname arguments
  38. when mode='DEBUG' then
  39.   address COMMAND DEBUGGER projectname arguments
  40. otherwise do
  41.   say 'Unknown RUNMODE: "'mode'"'
  42.   exit(10)
  43.   end
  44. end
  45. exit(RC)
  46.