home *** CD-ROM | disk | FTP | other *** search
/ Shareware 1 2 the Maxx / sw_1.zip / sw_1 / COMM / SCR104A.ZIP / GENERATE.DOC < prev    next >
Text File  |  1992-01-11  |  23KB  |  541 lines

  1. (C) Gale Green, Databeat Limited, Aylesbury, Bucks, HP21 8QP.
  2.  
  3. N.B. The program GENERATE.EXE plus its associated files and
  4. documentation may be distributed only as part of the Scripta
  5. package.
  6.  
  7. GENERATE.EXE MAY NOT BE DISTRIBUTED ON ITS OWN.
  8.  
  9.  
  10. The Scripta GENERATE Program
  11. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  12. Overview
  13. ~~~~~~~~
  14.  
  15. GENERATE combines a set of parameter files with information 
  16. supplied by yourself to produce a Scripta script (.CMD) file. 
  17.  
  18. This initial release contains four generators -
  19.  
  20.        WC2TC2 - for BBSs running Wildcat plus Tomcat at version 2
  21.        WC3TC3 - for BBSs running Wildcat plus Tomcat at version 3
  22.        PCBQM4 - for BBSs running PCBoard plus Qmail at version 4
  23.        RARAM3 - for BBSs running RemoteAccess plus RAMail at version 3
  24.  
  25. I know of far more Wildcat 3 boards than any other type with the
  26. result that WC3TC3 has received much wider exposure than the other
  27. two.
  28.  
  29. RARAM3 is very new and has only been used on one board. By the next
  30. release of Scripta, it will be suitable for any RemoteAccess board
  31. running RAMail 3 but for the time being scripts may need a little
  32. tweaking. The instructions given below were written before the
  33. RARAM3 generator was ready so, just for this release, follow the
  34. instructions given for PCBoard/Qmail scripts. It will quickly become
  35. obvious which bits don't apply to RAMail, when you come to generate
  36. the script.
  37.  
  38. Although it cannot be guaranteed that *every* script will work for
  39. *every* board, you should find that the scripts need only very minor
  40. tweaking in order to work on any BBS of the given type. *Most* scripts
  41. should work unchanged on *most* boards of any type.
  42.  
  43. I personally use Scripta-generated scripts, unchanged, on
  44. 18 WC3TC3 boards, 2 WC2TC2 boards, 2 PCBQM4 boards and 1 RARAM3
  45. board.
  46.  
  47. I will be exceedingly grateful for ALL feedback on the script
  48. generators - I want to make them absolutely fool-proof as
  49. quickly as possible.
  50.  
  51. If you have problems which you cannot resolve, perhaps because
  52. you're not the programming type, then please message me via any
  53. of the nets and BBSs listed in the Scripta documentation. I will
  54. be more than pleased to *make* the generators work for you.
  55.  
  56. Very soon, these generators will be made to work for *any* WCTC,
  57. RARAM or PCBQM board and other board/door combinations will be
  58. added as I find the time to do the work.
  59.  
  60. If you do have to tweak a script to make it work, please let me
  61. know what you had to do - I can then automate that step for a
  62. future release.
  63.  
  64. The scripts, as generated, will automatically log on, upload and 
  65. download both files and messages, and then log off. If you wish 
  66. to spend more time online, perhaps browsing bulletins or 
  67. whatever, then you can quit a script at any time while it is 
  68. running by pressing the Esc key. The remainder of the online 
  69. session is then conducted manually with yourself in full control.
  70.  
  71. To generate your first script, please follow carefully the steps
  72. outlined below. After that, you will find that script generation
  73. is very straightforward and you will probably never need to refer
  74. to these instructions again.
  75.  
  76. How GENERATE works
  77. ~~~~~~~~~~~~~~~~~~
  78. If a bulletin board has telephone number 123-456-789 then a 
  79. script used to access this board will contain somewhere within it 
  80. the command
  81.  
  82.                  DIAL "123-456-789"
  83.  
  84. Obviously, such a script may be used only to call that particular 
  85. board because the telephone number is unique.
  86.  
  87. GENERATE uses Template scripts which contain commands like the
  88. following
  89.  
  90.                  DIAL "@numberA"
  91.  
  92. and then, on demand, it generates 'real' scripts in which the
  93. @numberA syntax in the Template is replaced by a real telephone
  94. number.
  95.  
  96. The telephone number is used here as an example but there are 
  97. several items of information which are treated in exactly the 
  98. same manner: Username, Password, mail packet name, and so on.
  99. Anything, in fact, which is likely to be unique to a single
  100. BBS.
  101.  
  102. This initial release of GENERATE contains three template scripts
  103. named WC2TC2.TEM, WC3TC3.TEM and PCBQM4.TEM.
  104.  
  105. The first of these may be used to generate scripts for boards 
  106. which run Wildcat! plus Tomcat! at version 2; the second may
  107. be used for boards which run Wildcat! plus Tomcat! at version 3;
  108. the third may be used for boards running PCBoard plus Qmail at
  109. version 4.
  110.  
  111. Associated with each .TEM (template) file is a .PAR (parameter) 
  112. file. This contains a list of all the @keywords which may be used 
  113. in the .TEM file.
  114.  
  115. In order to generate a script, the GENERATE program needs a 
  116. further file, a .CFG (Configuration) file, which contains the 
  117. list of real values which are to be used to replace the @keywords 
  118. in the template.
  119.  
  120. Given such a file, named e.g., MYBBS.CFG, the GENERATE program 
  121. will produce MYBBS.CMD, a fully-working Scripta script file.
  122.  
  123. As examples, the GENERATE package includes .CFG files to enable
  124. the generation of the script files listed in the Scripta sample
  125. Dialling Directory. If you look at these examples, and generate
  126. one or two scripts, you'll see that the process is really very
  127. straightforward.
  128.  
  129. You may automate the entire process of BBS script generation by 
  130. invoking the supplied Scripta script named MAKE. This in turn
  131. will invoke one of the sub-scripts: MAKETC2.CM0, MAKETC3.CM0 or
  132. MAKEQM4.CM0.
  133.  
  134. These scripts will prompt you for the information they require, 
  135. create a .CFG file, and then call GENERATE to create a .CMD file.
  136.  
  137. To run the 'MAKE' script, first run Scripta, then press Alt/S.
  138. This will display the Script Selection Menu. Highlight the
  139. name of the MAKE script then press the Return key.
  140.  
  141. You will first be asked for the QWK packet name used on the
  142. BBS for which you want to generate a script. This name is used
  143. to form the name of the script file so GENERATE can check
  144. straight away to see if you already have a script for this
  145. BBS.
  146.  
  147. If a script already exists, you will next be allowed to edit the
  148. associated .CFG file, preparatory to optionally generating a new
  149. script. Otherwise, you will be asked whether the BBS is of Qmail,
  150. Tomcat or Tomcat v2 type. Press Q, T or 2. MAKE will then call the
  151. appropriate sub-script to create a new .CFG file.
  152.  
  153. The sub-script will first ask you for all the information it needs,
  154. then generate a new .CFG file and finally generate the .CMD file
  155. by calling the GENERATE program.
  156.  
  157. In order to generate a script for any given BBS, unless you
  158. already know the relevant details, you will first need to call
  159. the BBS manually. This is because one of the vital pieces of
  160. information needed to generate the script is the name used by
  161. the BBS for its mail (.QWK) packets and you can only find this
  162. out by logging on and downloading a packet. Mail packet names
  163. always have an extension of .QWK so typical names are
  164. MYBOARD.QWK, SOMEBBS.QWK, and so on.
  165.  
  166. GENERATE needs to know the first part of this name, e.g., 
  167. MYBOARD, SOMEBBS, etc., in order to generate a script. This name 
  168. is also used to form the names of the .CFG and .CMD files.
  169.  
  170. Note that, to generate a script from one of the supplied .CFG
  171. files, say THENET.CFG, run the MAKE script as described above
  172. and, when asked for the 'packet name used by the BBS', just enter
  173. the .CFG file name, e.g., THENET.
  174.  
  175. Thereafter, the fields which you need to fill in will be marked
  176. with six asterisks - ******.
  177.  
  178. *******************************************************************
  179. It is highly recommended that you print out this document for
  180. reference before proceeding with the steps outlined below.
  181.  
  182. Once you have generated your first few scripts, you will find
  183. it a very straightforward process. Until then, it will be best
  184. to follow these instructions to the letter. This will avoid
  185. making silly errors which will put you off script generation
  186. for life.
  187. *******************************************************************
  188.  
  189. So, for instance, suppose that you want to generate a script to 
  190. automate access to a Bulletin Board named The Dogs' Home.
  191.  
  192. You already have its telephone number so arm yourself with pen 
  193. and paper, write down the telephone number for later use and then 
  194. dial the board and log on. To dial the number, run Scripta and 
  195. then press Alt/D. This will take you to the dialling directory 
  196. where you can either set up a new entry or just press N to enter
  197. and dial the number manually.
  198.  
  199. The next thing to note on your piece of paper is whether or not 
  200. you have to pass through a 'gateway' or 'drawbridge' in order to
  201. reach the BBS. If after connection you are told to "press Esc
  202. twice to enter The Dogs' Home", or something similar, then this
  203. is a gateway.
  204.  
  205. Before pressing any keys, make a note of some unique and 
  206. recognisable string of characters in the gateway prompt and also 
  207. write down the response it has asked you to type. In the present 
  208. example, you might write down
  209.  
  210.           Home      EscEsc
  211.  
  212. 'Home' is a recognisable part of the prompt and 'EscEsc' is what 
  213. you have been asked to type.
  214.  
  215. In fact, you should write ^[^[ rather than EscEsc because Scripta 
  216. uses the character pair ^[ to represent the Esc key. Literally, 
  217. ^[ represents the action of holding down the Ctrl key and 
  218. simultaneously pressing the [ key.
  219.  
  220. Try it now. You've been asked to 'press Esc twice'. Instead, hold 
  221. down the Ctrl key and press the [ key twice. It will be just as 
  222. though you had pressed Esc twice.
  223.  
  224. The 'recognisable string' that you choose should contain characters
  225. which are all displayed in the same colour. For instance, in the
  226. present example, we have chosen the string 'Home'. If the 'H'
  227. were displayed in red and the 'ome' in yellow then 'Home' would not
  228. do - some other string would have to be chosen, perhaps 'ome'.
  229.  
  230. The reason for this is that colours are changed using ANSI Escape
  231. Sequences which, while invisible, are still there and would
  232. confound any attempt at matching a string.
  233.  
  234. As you log into the BBS, the opening screens should tell you the
  235. type and version of the BBS. e.g., PCBoard, Wildcat! 3.00, and
  236. so on.
  237.  
  238. Remember that you can only use GENERATE for Wildcat and PCBoard
  239. BBSs. For other BBS types, you will have to use the
  240.  
  241.                   SCRIPTA //<script_name>
  242.  
  243. option to generate simple scripts until you learn to write your
  244. own scripts or I release a .TEM file for that type.
  245.  
  246. Something to remember for later, when you're more used to BBSs,
  247. is that you will find scripts much more reliable and efficient,
  248. on any BBS, if you select the 'Expert' mode online. For PCBoard,
  249. just press X and then a Carriage Return, at the Main Menu. On
  250. Wildcat boards, press H (for Help level) at the Main Menu and
  251. then press E for Expert mode.
  252.  
  253. When you have entered the bulletin board proper and logged in, the
  254. board will display its Main Menu. This is simply a menu from which
  255. you can select items which cause you to leap into other parts of
  256. the Bulletin Board. The part we are interested in is the mail
  257. door - we need to find out the name that the board uses for its
  258. mail packets.
  259.  
  260. If this is your first call to a Wildcat board then during the 
  261. login sequence you will be asked whether you want to use Hot 
  262. keys. Answer Yes. If you don't, then any scripts that you 
  263. generate will not work.
  264.  
  265. If you are calling a PCBoard BBS, you will also be asked
  266. whether you require ANSI graphics. On your piece of paper,
  267. write down Y if you have a colour monitor or N otherwise.
  268. Then press the key you have written down followed by a
  269. Carriage Return.
  270.  
  271. Whilst still at the Main Menu, and before you press any keys,
  272. and if this is a Wildcat! version 2.nn BBS, note down the last
  273. few characters at the foot of the menu. They will be some kind
  274. of prompt like > or >> or : or maybe a word like Next? or,
  275. depending on the help level you have set, you may not see a proper
  276. menu, you may just see a line saying something like 'MAIN MENU:'.
  277. Whatever you see, note down the final few characters (say, two to
  278. ten characters). Later, when you create your script and then run
  279. it, Scripta will use these characters to recognise menus during
  280. automatic BBS runs.
  281.  
  282. Again, only if this is a Wildcat version 2.nn BBS, press F.
  283. This will take you to the Files Menu where once again you
  284. should note down the prompt at the foot of the menu. Then,
  285. press Q to return to the Main Menu.
  286.  
  287. Next, on Wildcat boards of any version, press M. This will
  288. take you to the Messages Menu. If it is a Wildcat! version 2.nn
  289. BBS, note down the prompt at the foot of the menu, just as you
  290. did at the Main and Files Menus.
  291.  
  292. Then, read the menu, note down the key that you have to press
  293. to enter the Tomcat! mail door, usually T for Tomcat or O for
  294. Offline mail, and then press that key.
  295.  
  296. On PCBoard boards, first of all note down something recognisable
  297. from the last line of the Main Menu, as described for Wildcat
  298. 2.nn boards, and then scan the main menu for a reference to 'mail
  299. door', 'Qmail door', 'offline mail' or something similar. Note 
  300. down what you have to type to enter the door, and then type it.
  301. It will probably be a command like QMAIL or MAIL, or an
  302. instruction to open a door, like OPEN 7. If you can't see
  303. anything helpful, just type OPEN and press Return. You will be
  304. shown a list of door numbers. Note down the word OPEN followed
  305. by the number of the Qmail door, as shown on-screen. Then,
  306. type in the door number and press Return.
  307.  
  308. Once you have reached the mail door, either Tomcat or Qmail, 
  309. press C for Configure. If it is a Qmail door, you'll also have to 
  310. press Return after the C.
  311.  
  312. At the Configuration Menu, select all the conferences that you 
  313. wish to be included in your mail packets and reset the pointers 
  314. in those conferences to a fairly high number so that you don't 
  315. download hundreds of messages on this, your first, download.
  316.  
  317. It is worth spending a bit of time at the Configuration Menu. 
  318. Accessing the board in future, using GENERATE scripts, will be 
  319. very fast and very cheap so it's worth the time now to make sure
  320. that the door is set up the way you want it.
  321.  
  322. If there are Configuration items that you don't understand LEAVE 
  323. THEM ALONE! Do not fiddle with things unnecessarily, you can 
  324. always come back at a later date if things aren't quite right.
  325.  
  326. In Qmail doors, do not set any options which involve logging off. 
  327. For example, there is an option to log off after uploads. If you 
  328. set this option, your scripts will not work properly. Once set 
  329. up, your scripts will handle all logging on and logging off.
  330.  
  331. In Qmail doors, you should set the default protocol to Zmodem. In
  332. Tomcat doors, set the Transfer Protocol either to Zmodem or to
  333. 'Select each time'.
  334.  
  335. When you have finished at the Configuration Menu, press Q to 
  336. Quit. Again, in Qmail doors, you will have to press Q followed by 
  337. the Return key.
  338.  
  339. You will now return to the proper mail door menu where you should 
  340. press D for Download. (D<return> in Qmail doors).
  341.  
  342. The mail door will now assemble your mail packet in a file called 
  343. something.QWK and initiate a download so that you can transfer 
  344. the packet from the BBS into your own computer.
  345.  
  346. When the mail door is ready to download, it will display a
  347. message something like the following:
  348.  
  349. Prepare to download something.QWK
  350.  
  351. First, make a note of the 'something'. Continuing the earlier 
  352. example, a mail packet from The Dogs' Home BBS will probably be 
  353. called DOGS.QWK, or HOME.QWK or DOGSHOME.QWK
  354.  
  355. Next, if you have Auto Zmodem set in Scripta configuration, the 
  356. mail packet will be downloaded automatically. Otherwise, do it 
  357. manually by pressing the PgDn key, followed by Z for Zmodem and 
  358. then a Carriage Return.
  359.  
  360.                PgDn Z <return>
  361.  
  362. When the download has finished, press G for Goodbye (G followed 
  363. by a Carriage Return if this is a Qmail door).
  364.  
  365. Your piece of paper now contains all the information you need to 
  366. generate a script to access The Dogs' Home BBS.
  367.  
  368. Still within Scripta, press Alt/S. This will display the script 
  369. selection menu. Highlight the name 'MAKE' and press Return.
  370.  
  371. You will then be asked which generator to use - press 'Q' for
  372. Qmail, 'T' for Tomcat! version 3 or '2' for Tomcat! version 2.
  373.  
  374. A further screen will be displayed in which you can enter the 
  375. information from your piece of paper (plus some more odds and 
  376. ends like your username and password on the BBS for which the 
  377. script is being generated). When you have finished entering the 
  378. information, the script will be generated.
  379.  
  380. If you have several pieces of paper, from several BBSs of the
  381. same type, then you can generate all your scripts at this screen,
  382. one after the other. When you have finished, press Esc or Return
  383. on a blank field to exit back to Scripta.
  384.  
  385. If you now press Alt/S again, you will see that DOGSHOME, or 
  386. whatever the .QWK packet name was, has miraculously appeared in 
  387. your script selection menu from where you can run it as often as 
  388. you wish.
  389.  
  390. Once a script has been generated in this manner, it may be run in 
  391. several ways. You can press Alt/S at the Scripta Command Mode 
  392. Screen, to call up the Script Selection screen, as above. You can 
  393. also enter the following at the DOS prompt:
  394.  
  395.                 SCRIPTA <script_name>
  396.  
  397. Or finally, you can set up an entry in the Scripta Dialling 
  398. Directory. Just press Alt/D within Scripta to call up the 
  399. Dialling Directory and then press Ins to Insert a new entry.
  400.  
  401. Summary of Script Generation Process
  402. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  403. This has been quite a lengthy description of what is really a 
  404. very straightforward process. In summary, to generate a script,
  405. do the following:
  406.  
  407.   1. Write down the phone number(s) of the BBS.
  408.  
  409.   2. Log onto the BBS and find out if there is a gateway. If 
  410.      there is, note the prompt and the required response.
  411.  
  412.   3. Still online, go to the mail door, configure it, ask for a
  413.      download and note the .QWK packet name.
  414.  
  415.      If it is a Wildcat! version 2 BBS, remember on your way
  416.      to the mail door to note the prompts at the Main Menu and
  417.      Messages Menu.
  418.  
  419.      Whatever kind of BBS it is, note down what you have to type
  420.      to enter the mail door (from the Messages Menu on Wildcat!
  421.      boards or from the Main Menu on PCBoard boards).
  422.  
  423.   4. In Scripta, press Alt/S, highlight 'MAKE' and press Return.
  424.  
  425.   5. Enter the information from your piece of paper and generate 
  426.      the script.
  427.  
  428. If you want to generate one of the example scripts included with
  429. the package then miss out steps 1 to 3 above. Just run the 'MAKE'
  430. script and, when it asks for the BBS mail packet name, just tell
  431. it the name of the .CFG file from which you want a script to be
  432. generated.
  433.  
  434. Then, keep pressing Return until you are asked whether to continue
  435. with script generation. Then, press Y.
  436.  
  437. What the generated scripts do
  438. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  439. A generated script called say SOMEBBS.CMD, when executed by Scripta,
  440. performs the following actions:
  441.  
  442.   1. Dial the BBS, log on, and go to the Main Menu.
  443.  
  444.   2. Check for the existence (in your Scripta directory) of files
  445.      named SOMEBBS.FUL or SOMEBBS.FDL.
  446.  
  447.      If SOMEBBS.FUL exists, upload all the files whose DOS pathnames
  448.      are listed within it. Each such pathname may contain * or ? DOS
  449.      wildcard characters.
  450.  
  451.      If SOMEBBS.FDL exists, download to the Scripta default download
  452.      directory all the files whose simple names are listed within it.
  453.  
  454.   3. Enter the online mail door.
  455.  
  456.   4. If SOMEBBS.PTR exists in your default Scripta upload directory,
  457.      then upload it to the mail door.
  458.  
  459.   5. If SOMEBBS.REP (a mail reply file) exists in your default
  460.      Scripta upload directory then upload it to the mail door.
  461.  
  462.   6. Download SOMEBBS.QWK (a mail packet) to your Scripta default
  463.      download directory.
  464.  
  465.   7. Log off.
  466.  
  467. If you are a Power-QWK user then SOMEBBS.FDL is created automatically
  468. when you pick filenames off the new files listing by pressing D for
  469. Download or out of a message by pressing Ctrl/F for Filename.
  470.  
  471. Debugging scripts
  472. ~~~~~~~~~~~~~~~~~
  473. If you run a script which then 'hangs' when online then this usually
  474. means one of two things: either the script has been set up to expect
  475. a string from the remote which has not been received, or, the expected
  476. string has been received too early, usually because the Sysop has
  477. included a vital string in some piece of text like a welcome screen.
  478.  
  479. When a script 'hangs', press F3. This will cause Scripta to show you
  480. what strings it is currently waiting for. By comparing these with
  481. what has actually been received (this will still be on-screen),
  482. you will be able to deduce what the script *should* be waiting for
  483. and be able to edit the script accordingly.
  484.  
  485. Remember, the scripts are not guaranteed to work unchanged on all
  486. BBSs. They will work unchanged on *many* BBSs and will require
  487. minor change in order to work on other BBSs.
  488.  
  489. F3 is the most useful key at your disposal in the debugging of new
  490. scripts.
  491.  
  492. If you need to look back over the current session, press Alt/v.
  493. Unless you are running a script from within Power-QWK, this will
  494. display the review buffer, containing all that has been sent to
  495. or received from the remote system during the current session.
  496.  
  497. If you want to record a session in a disc file so that you can
  498. peruse it later, press Alt/L to switch logging ON, before you
  499. run the script.
  500.  
  501. Note
  502. ~~~~
  503. In the script generator screens, there are spaces to enter up to
  504. four telephone numbers. There must be NO GAPS in the spaces
  505. used. In other words, you can enter items 1, 2 and 3 but NOT
  506. items 1, 3 and 4 (leaving item 2 blank).
  507.  
  508. To blank out a telephone number, just set the first character
  509. to * (asterisk).
  510.  
  511. And finally...
  512. ~~~~~~~~~~~
  513. I hope you like this program. It has been designed to make life 
  514. as easy as possible for the BBS newcomer and expert alike.
  515.  
  516. The script generator will become more and more robust as time 
  517. passes and more and more people use it to access different BBSs.
  518.  
  519. If you find that a generated script won't work on a particular 
  520. board, PLEASE let me know so that I can make the necessary 
  521. changes to ensure that it works in future releases.
  522.  
  523. In the fulness of time, I will be producing more templates for 
  524. other BBS/mail door combinations. If YOU produce a template for a 
  525. particular combination then by all means send it in for inclusion 
  526. in the GENERATE package. I will acknowledge you in the 
  527. documentation and you will get warm glows from knowing that you 
  528. have helped someone else to enjoy their BBSing a little bit more.
  529.  
  530. If you're an experienced telecommunicator, remember how 
  531. frustrating were your own early days and how expensive it can be 
  532. getting to know a BB system like PCBoard. Any way that newcomers
  533. can be helped will ensure that our hobby expands and thereby 
  534. becomes more interesting for us all.
  535.  
  536. If you have any comments on the product, or requests for 
  537. additional facilities then, again, please let me know. If you 
  538. don't ask, you don't get!
  539.  
  540. Gale Green (author).
  541.