home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 3 / BBS in a box - Trilogy III.iso / Files / Tele / A / AnalyzeCL Utils Folder / BBS Macros Listing < prev    next >
Encoding:
Text File  |  1993-12-14  |  4.6 KB  |  217 lines  |  [TEXT/QED1]

  1. "Unbreak Text" macro def.
  2. # This will replace all <returns> between selected lines with a space.
  3. # Double spaced lines and lines that begin with a space, tab, or
  4. # asterisk are not affected.  
  5. Unbreak Text
  6. Change "" "" "gst-w-G"
  7. Set Line Width
  8. Key 74
  9. Key 
  10. Change "\r\r" "\0" "gst-w-G"
  11. Change "\([^\0]\)\r\([^ \t\*]\)" "\1 \2" "gst-w-G"
  12. Change "\0" "\r\r" "gstA-w"
  13. Change ":b$" "" "gst-w-G"
  14.  
  15.  
  16. "Break Text" macro def.
  17. # This will will remove CRs using the Unbreak Text macro,
  18. # then set the line width, wrap the lines, and add CRs
  19. # This is very useful for formatting BBS Bulletins.
  20. Change Tabs ->Spaces
  21. Set Line Width
  22. Key 74
  23. Key 
  24. Change " :^\([^\r]\)" "\r\1" "gst-w-G"
  25. Change ":s\r+" "" "gst-w-G"
  26. Change "\r+:e" "" "gst-w-G"
  27. Set Line Width
  28. Key None
  29. Key 
  30.  
  31.  
  32.  
  33. "Plot Usage" macro def.
  34. # Select lines containing usage figures. (Must be followed by '%')
  35. # This will convert the numeric data into a simple text plot.
  36. Copy "8"
  37. New "Usage Plot"
  38. Paste "8"
  39. Change "\( *[^- ]*\).:*\(:#+\)%.*"  "\1  \2%  \0\2" "g-wat"
  40. Change " \(:#%\)" "  \1" "g-wat"
  41. Change "\0\(:#\)$" "\00\1" "g-wat"
  42. Change "\01" "\0•" "g-wat"
  43. Change "\02" "\0••" "g-wat"
  44. Change "\03" "\0•••" "g-wat"
  45. Change "\04" "\0••••" "g-wat"
  46. Change "\05" "\0•••••" "g-wat"
  47. Change "\06" "\0••••••" "g-wat"
  48. Change "\07" "\0•••••••" "g-wat"
  49. Change "\08" "\0••••••••" "g-wat"
  50. Change "\09" "\0•••••••••" "g-wat"
  51. Change "\00" "\0" "g-wat"
  52. Change "\0" "" "g-wat"
  53. Change "•" "**********" "g-wat"
  54. Change "1$" "*" "g-wat"
  55. Change "2$" "**" "g-wat"
  56. Change "3$" "***" "g-wat"
  57. Change "4$" "****" "g-wat"
  58. Change "5$" "*****" "g-wat"
  59. Change "6$" "******" "g-wat"
  60. Change "7$" "*******" "g-wat"
  61. Change "8$" "********" "g-wat"
  62. Change "9$" "*********" "g-wat"
  63. Change "0$" "" "g-wat"
  64. ## The next two lines will scale the data 2:1  (untested)
  65. # Change "**" "!" "-gs"
  66. # Change "*" "" "-gs"
  67. ## Or this line will double the scale for increased differential
  68. # Change "*" "!!" "-gs"
  69.  
  70.  
  71.  
  72. "Separate Stats" macro def.
  73. # Open a 'CL Analysis' file (name is not important) and
  74. # run this macro.  It will extract various reports and
  75. # put them in separate files with tab delineation between
  76. # fields.
  77. Jump "1"
  78. Set Marker "ACL"
  79. Find "Monthly Report"
  80. Find "^ *:#:?:*\r^$" "gA"
  81. Copy "0"
  82. New  "Monthly Stats"
  83. Paste "0"
  84. Change "%" "" "-ga"
  85. Change "^ +" "" "ga"
  86. Change " +" "\t" "ga"
  87. Select All
  88. Copy "0"
  89. Save
  90. Close
  91. Jump "ACL"
  92. Find "Weekly Report"
  93. Find "^ *:#:?:*\r^$" "g"
  94. Copy "0"
  95. New  "Weekly Stats"
  96. Paste "0"
  97. Change "%" "" "-ga"
  98. Change "^ +" "" "ga"
  99. Change " +" "\t" "ga"
  100. Select All
  101. Copy "0"
  102. Save
  103. Close
  104. Jump "ACL"
  105. Find "Day Report"
  106. Find "^:A" "g"
  107. Find "^:A:?:*\r^$" "g"
  108. Copy "0"
  109. New  "Day Of Week Stats"
  110. Paste "0"
  111. Change "%" "" "-ga"
  112. Change " +" "\t" "ga"
  113. Select All
  114. Copy "0"
  115. Save
  116. Close
  117. Jump "ACL"
  118. Find "Daily Report"
  119. Find "^ *:#:?:*\r^$" "g"
  120. Copy "0"
  121. New  "Daily Stats"
  122. Paste "0"
  123. Change "%" "" "-ga"
  124. Change "^ +" "" "ga"
  125. Change " +" "\t" "ga"
  126. Select All
  127. Copy "0"
  128. Save
  129. Close
  130. Jump "ACL"
  131. Find "Hourly Report"
  132. Find "^ *:#:?:*\r^$" "g"
  133. Copy "0"
  134. New  "Hourly Stats"
  135. Paste "0"
  136. Change "%" "" "-ga"
  137. Change "\- -:#+\::#:#" "" "ga"
  138. Change "^ +" "" "ga"
  139. Change " +" "\t" "ga"
  140. Select All
  141. Copy "0"
  142. Save
  143. Close
  144. Jump "ACL"
  145. Set Marker "ACL"
  146. Close
  147.  
  148.  
  149. "Sort List Of Menus" macro def.
  150. #  This particular macro is obsolete, since I added this capability to
  151. # ListMenus 3.5.  It is included to show what QUED/M macros are capable 
  152. # of.  It will sort the menus in a pre 3.5 List Of Menus file according
  153. # to the order in the hierarchy table.
  154. Open ":List Of Menus"
  155. Find "^  1   1" "ga-w"
  156. Find "^" "rg-w"
  157. Set Marker "S"
  158. Find "^$" "g-w"
  159. Jump "S"
  160. Cut "8"
  161. New ":Ordered List"
  162. Paste "8"
  163. Change ":b*:#+:b*:#+ *" to "" "gat-w"
  164. Change ^$\r" to "" "gat-w"
  165. Jump "1"
  166. Set Marker "Order"
  167. Sort BBS Menus1
  168. Open ":List Of Menus"
  169. Jump "1"
  170. Paste "8"
  171. Jump "Order"
  172. Close
  173. Key n
  174. :1 "The List Of Menus file is now ordered."
  175.  
  176.  
  177. "Sort BBS Menus1 " macro def.
  178. # This macro is used recursively by Sort List Of Menus
  179. Jump "Order"
  180. Find "^\:.*$"  "Tg-w"
  181. Cut "0"
  182. Open ":List Of Menus"
  183. Jump "1"
  184. Find '\*\*\*\*\*\*  "\C0'  "av-g-w"
  185. Find "^" "gr-wt"
  186. Set Marker "S"
  187. Find "^[ \<\>]="  "gt"
  188. Find "\r^$"  "g-wt"
  189. Find "^"   "g-wt"
  190. Jump "S"
  191. Cut "8"
  192. Sort BBS Menus1
  193.  
  194.  
  195.  
  196.  
  197. "Sort By ULs" macro def.
  198. # This macro assumes that the user data has been placed in the current
  199. # file.  It will sort the data according to the UL count, deleting all
  200. # users who have 0 uploads.
  201. Change "/ \(:d/8[678]\)" "/0\1" "ga-wt-G"
  202. Change "^\(.:*\)\.\.+:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*:b+.:*\(:#+\).*" to "\2\t\1" "gat-w"
  203. Select All
  204. Sort Lines
  205. Change "^0.*\r" to "" "g-wa"
  206. Copy "9" ""
  207. Jump "END"
  208. Invert Line Order
  209. Paste "9"
  210.  
  211.  
  212. "Invert Line Order" macro def.
  213. # This is a recursive macro used by Sort By ULs
  214. Find "^.*\r" "gT-wr"
  215. Cut "9"
  216. Invert Line Order
  217.