home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 17 / CD_ASCQ_17_101194.iso / vrac / ecopy200.zip / ECOPY.DOC < prev    next >
Text File  |  1994-09-14  |  16KB  |  368 lines

  1. ▄▄▄▄▄▄▄▄▄       ▄▄▄▄▄▄▄   ▄▄▄▄▄▄▄    Chris Jantzen
  2. █  ▄▄▄█ █▄▄▄▄▄▄▄█  ▄▄▄█▄▄▄█ ▄▄█ █▄   SlugSoft
  3. █▄▄▄  █ █ █ █ ▄ █▄▄▄  █ ▄ █ ▄█▄ ▄█┐  1880 Ocean Blvd. SE
  4. █▄▄▄▄▄█▄█▄▄▄█▄▄ █▄▄▄▄▄█▄▄▄█▄█│█▄█┌┘  Coos Bay, OR  97420-1911
  5.  └─────┴─┴──█▄▄▄█ ├────┴───┴─┘ └─┘   USA
  6.              └────┘                  FidoNet 1:356/24
  7.  
  8.  
  9.                               ECOPY v2.00
  10.  
  11.                  DOS command line enhanced copy program
  12.  
  13.  
  14.  
  15. INTRODUCTION
  16.  
  17. ECOPY provides services for copying files using XMS and EMS to speed
  18. disk usage. It provides DISKCOPY-like functions and can even swap to a
  19. fixed drive for extra memory if told to.
  20.  
  21. This program is designed for the "power user". If you are uncomfortable
  22. at the DOS prompt, then this program might not for you. If you thrive at
  23. the DOS prompt, then this program may become one of your better friends.
  24. To learn about the program, study the help screen ('ECOPY /?').
  25.  
  26. The program notes and details were moved to this documentation as of
  27. version 1.60. Before reading the following program notes, please study
  28. the help screen to familiarize yourself with calling conventions.
  29.  
  30.  
  31. PROGRAM NOTES
  32.  
  33. ■ If only one source is provided, the destination path is assumed to be
  34. the current directory. If more than one source is provided, then last
  35. path on the command line is assumed to be the destination path (be
  36. careful, this one's bitten me more than once <grin>). Note that the
  37. destination is always a directory--ECOPY will not rename or concatenate
  38. files when copying like XCOPY and COPY.
  39.  
  40. ■ Default commands can be set with the ECOPYCMD environment variable
  41. (e.g., entering SET ECOPYCMD=/STD on the command line would force ECOPY
  42. to always use standard output for critical errors).
  43.  
  44. ■ The path used for data swapping (if enabled) or temporary storage for
  45. disk spanning is taken from the environment variable TEMP or assumed to
  46. be C:\.
  47.  
  48. ■ Commands with the "(XCOPY)" notation listed beside them are mostly
  49. compatible with MS-DOS XCOPY commands. DISKCOPY and XCOPY are copyright
  50. material by Microsoft Corp., this program does not use code from XCOPY
  51. or DISKCOPY nor is it reverse engineered in any way from XCOPY or
  52. DISKCOPY.
  53.  
  54. ■ Multiple wildcards may be specified while only specifying one source
  55. directory by placing a semicolon between each. See examples. This
  56. feature can be extremely helpful for carefully selecting source files of
  57. specified patterns from a long source path. Note that this feature is
  58. similar to a feature of 4DOS/NDOS's COPY include list command.
  59.  
  60. ■ The date for the /D and /B commands must be entered as numbers in your
  61. native country specific order with date seperators (e.g., in the USA
  62. date format, 4-14-91 would represent 14 Apr 91). If the date seperator
  63. you like to use is the same as your switch character then it is
  64. absolutely necessary to enclose the date in quotation marks (e.g.,
  65. /D:"4/14/91"). Also note that any date-like seperator is accepted.
  66.  
  67. ■ For file selection, /I is applied first to include files with special
  68. attributes, then /X is applied to exclude unwanted files, then /D is
  69. applied to catch files after the specified date, and finally the /B
  70. parameter is applied to catch files before a date.
  71.  
  72. ■ The attribute descriptor for the /I and /X commands is a list of one-
  73. letter descriptors for the Read-only, Hidden, System, and Archive
  74. attributes. For example, /X:RASH would only copy files that did NOT have
  75. any attributes set; /I:RSH would only copy files that had no attribute,
  76. the Read-only attribute, the System attribute, and/or the Hidden
  77. attribute set. Note that /I:RA is automatically implied unless changed
  78. manually, or unless /A or /M are used. Also, each successive /I or /X
  79. resets the previous setting--the commands are not cumulative. Last
  80. note--two special "attributes" exists--the X attribute is a pseudonym
  81. for all the attributes: /I:X is the same as /I:RASH; the B attribute is
  82. a pseudonym for NO attributes (/I always has an implied B tacked on):
  83. /I:R/X:B would only select files with just the Read-only attribute set.
  84. The /A command is simply a simplified form of /I:RA/X:B and the /M
  85. command is a slightly advanced form of /A that toggles the Archive
  86. attribute off.
  87.  
  88. ■ How /I and /X REALLY work: /I includes all files with attributes set
  89. as specified or not (e.g., /I:RA will match all files with Read-only and
  90. Archive, Read-only only, Archive only, or nothing at all); /I will not
  91. include files that attributes set that are not specified (e.g., /I:RA
  92. will not select files that have the Hidden or System attributes set).
  93. The /X parameter then excludes files from THIS reduced set if they have
  94. exactly the attributes specified (e.g., /I:RA/X:R would include all
  95. files as before but exclude files that had only the Read-only attribute
  96. set but would still accept files with the Read-only and the Archive
  97. attributes set). Confusing? These two commands can be very powerful if
  98. used carefully. As noted, the /A command is simply a macro for /I:RA/X:B
  99. to backup normal files that only have the Archive and optionally the
  100. Read-Only bit set (like XCOPY).
  101.  
  102. ■ How /IF and /XF work: First, all other selection criteria must be met
  103. (include /I and /X filters). Files are then excluded by /XF filespecs
  104. (note that you can specify more than one filespec, e.g.,
  105. /XF:*.EXE;*.COM) unless they match /IF filespecs. Consider the following
  106. example:
  107.  
  108. The directory in case contains the following files:
  109.  
  110. BOZO.DAT
  111. BOZO.EXE
  112. BOFFO.DAT
  113. BOFFO.EXE
  114. ECOPY.EXE
  115.  
  116. ECOPY *.* TEMP /XF:*.EXE /IF:BOZO.EXE
  117.  
  118. The following files will be copied to the TEMP subdirectory:
  119.  
  120. BOZO.DAT
  121. BOZO.EXE
  122. BOFFO.DAT
  123.  
  124. Note that all EXE files were excluded except for BOZO.EXE which was
  125. explicitly included. All other files passed through normally.
  126.  
  127. ■ The fill command requires both the source and destination to be
  128. online, so that the destination may be evaluated before reading the
  129. source files. (Normally only the disk being processed is required to be
  130. online as per the read/write cycle.) The QuickMove (/MV) also requires
  131. both the destination and source to be online simultaneously. Also note
  132. that if the /S command is used, the destination usually won't be filled
  133. optimally because of the internal routines used to anticipate the space
  134. used up by the directory structures themselves. /MD cannot be used in
  135. conjunction with /F.
  136.  
  137. ■ If the DIET TSR is installed, ECOPY will correctly determine the
  138. amount of space the files will take up after expansion by examining
  139. their headers. This can take a while, but the technique used is as fast
  140. as possible. DIET is copyright Teddy Matsumoto.
  141.  
  142. ■ The verify command actually reads the data off the disk and compares
  143. it to just-written data.
  144.  
  145.  
  146. EXAMPLES
  147.  
  148. ECOPY C:\ A:\ /X:RH
  149.   Copy any files in the root directory that do NOT have just the
  150.   Read-only and Hidden attribute set to the A: drive.
  151.  
  152. ECOPY C:\ A:\ /I:H/P/L
  153.   Copy all files in the root directory including Hidden files, asking
  154.   the user if he wants to copy each file, listing those he didn't choose
  155.   to copy.
  156.  
  157. ECOPY C:\WORK A:\ /F/A/Z
  158.   Move changed C:\WORK files to floppy, finding best fit.
  159.  
  160. ECOPY C:\ A:\ /DC/F/M
  161.   Backup hard disk to floppy, finding optimum use for floppies.
  162.  
  163. ECOPY A:\ C:\ /DC
  164.   Restore one backup disk to hard drive.
  165.  
  166. ECOPY A:\ A:\ /DC
  167.   Performs effective DISKCOPY.
  168.  
  169. ECOPY A:\ B:\ /DC/SW-
  170.   Performs effective DISKCOPY, but will not swap to temporary file.
  171.  
  172. ECOPY X:\A*;B* C:\TEMP
  173.   Copies X:\A*.* and X:\B*.* to C:\TEMP (note multiple wildcards).
  174.  
  175. ECOPY X:\A*; B* C:\TEMP
  176.   Same as above with different semicolon spacing--still valid.
  177.  
  178. ECOPY X:\A* ;B* C:\TEMP
  179.   Same as above with different semicolon spacing--still valid.
  180.  
  181. ECOPY X:\A* ; B* C:\TEMP
  182.   Same as above with different semicolon spacing--still valid.
  183.  
  184. ECOPY C:\WORK\PASCAL\PROJECTS\NEW\A*;B*;C* C:\TEMP
  185.   Illustrates how multi-selection can be helpful with long source path
  186.   names. This is equivalent to:
  187.  
  188.         ECOPY C:\WORK\PASCAL\PROJECTS\NEW\A*
  189.           C:\WORK\PASCAL\PROJECTS\NEW\B* C:\WORK\PASCAL\PROJECTS\NEW\C*
  190.           C:\TEMP
  191.  
  192.   On one line. Notice how the multi-selection version is much more
  193.   concise.
  194.  
  195. I'm afraid that's all the documentation available at this point.
  196.  
  197.  
  198. THE FUTURE
  199.  
  200. ECOPY is a constantly expanding project (now, if only the EXE would stop
  201. doing that!), and I have several plans for future upgrades that are
  202. listed in the history file. If you have any nifty ideas, send them with
  203. your registration, or mail them to the address above.
  204.  
  205.  
  206. KUDOS
  207.  
  208. Special thanks go out to the following:
  209.  
  210. Tim Van Over:   One of those all powerful influences in our area--he even
  211.                 bought me my first Turbo Pascal.
  212.  
  213. Mark Magill:    Sysop of The College BBS and general wonderful guy.
  214.  
  215. Jesse Williamson: He keeps prodding me into these projects--no,
  216.                 the order you appeared in this file is not of
  217.                 significance.
  218.  
  219. Fabrice Bellard: For his wonderful LZEXE program, and especially for allowing
  220.                 developers to use it for free.
  221.  
  222. Teddy Matsumoto: For his wonderful DIET program.
  223.  
  224. Anyone who took the time to read this (whew).
  225.  
  226. And especially YOU THE REGISTERED USERS (without whom I might not write
  227. this, or actually, without whom I appear to be writing this...).
  228.  
  229.  
  230. GENERAL NOTES
  231.  
  232. If you are running under a DOS version less than 3.0, then ECOPY may
  233. have trouble finding itself (and it's internal overlay if the version
  234. you are using has such). ECOPY will look in the PATH (starting in the
  235. current directory) and then try the ECOPY environment variable. To set
  236. ECOPY's path using the environment variable, type SET ECOPY=C:\UTILS\
  237. from the DOS prompt (if C:\UTILS\ is where you keep ECOPY). Substitute
  238. the path to ECOPY for C:\UTILS\ above. (Trailing backslash is not
  239. necessary, but doesn't harm things.)
  240.  
  241. If you experience trouble running ECOPY on a 386, set the environment
  242. variable NO386 to anything (e.g., SET NO386=Y) to disable 386
  243. instructions. (For example, it is known that older versions of QEMM will
  244. corrupt the 32-bit registers and cause irregular program behavior.) If
  245. you experience trouble running it on a non-386, you may also want to try
  246. disabling 386 instructions, just in case the CPU detection routines
  247. think your CPU is an 80386 (for whatever strange reason).
  248.  
  249. Also, ECOPY may maintain a SLUGSOFT.INI section. If it does, then by default
  250. it will create SLUGSOFT.INI in the root directory of the drive from which
  251. ECOPY was executed. If you have SlugSoft utilities stored on different
  252. drives, then you may want to use the SLUGSOFT environment variable. If
  253. you wish for SLUGSOFT.INI to reside in C:\UTILS, for example, you would
  254. type SET SLUGSOFT=C:\UTILS from the DOS command line.
  255.  
  256.  
  257. COMMAND LINE PARSING NOTES
  258.  
  259. ECOPY uses the standard SlugSoft command line parser, which means a certain
  260. number of useful features are built-in for your convienence. Here are some
  261. notes on special features:
  262.  
  263. ■ The parser will read default command line options using the ECOPYCMD
  264. environment variable. Say, for example, that you want (for whatever strange
  265. reason) to have ECOPY display its help screen each time it starts, you would
  266. simply type SET ECOPYCMD=/? from the DOS command line.
  267.  
  268. ■ By default anything seperated by a space or tab character is assumed to be
  269. another token on the command line. If you wish for several words to be
  270. considered as one token, then enclose them in quotation marks (""). E.g.,
  271. normally ECOPY ONE TWO would cause ECOPY to act on ONE and TWO, but
  272. ECOPY "ONE TWO" would cause ECOPY to act on ONE TWO.
  273.  
  274. ■ The parser will read an external file as part of the command line using
  275. the very standard @ operator. E.g., ECOPY @FILENAME would read the file
  276. named "FILENAME" and pretend that each line of the file were an additional
  277. command line to be parsed. If a line in the file starts with a semicolon
  278. (";") then it is assumed to be a comment and is NOT parsed. Each line can
  279. not exceed 255 characters, but the file can be as large as desired. If you
  280. wish to pass the @ character literally on the command line, then enclose
  281. it in quotation marks ("") like such ECOPY "@FILENAME".
  282.  
  283. ■ The parser will accept either a forward slash ("/") or a dash ("-") as a
  284. switch for command line commands. E.g., ECOPY -? and ECOPY /? will both work.
  285.  
  286. ■ The parser will automatically look for CmdMacro entries in the
  287. SLUGSOFT.INI file (located as specified above). Each entry must be named
  288. like CmdMacro=NAME MACRO. The macro name is specified as the first word
  289. (NAME above) and the macro value is everything else (MACRO above). An
  290. example:
  291.  
  292.         [ECOPY]
  293.         CmdMacro=HELP /?
  294.  
  295. If this were in SLUGSOFT.INI, then typing ECOPY /HELP on the command line
  296. would be the same as typing ECOPY /?. Command macros can replace built-in
  297. commands. In fact, command macros can even refer to each other. Be
  298. careful, though, as you can develop looping macros that will cause weird
  299. results. If you wish to refer to the original command in your macro,
  300. then precede the name with an asterisk ("*"), like so:
  301.  
  302.         [ECOPY]
  303.         CmdMacro=FROB /*FROB
  304.  
  305. You may also use the asterisk on the command line to use only the
  306. original internal command. There is one special consideration: All the
  307. CmdMacro entries MUST be grouped together. All entries after the first
  308. break will be ignored. Confusing? It's a very powerful feature if you
  309. can figure it out. (Or if I write better documentation.)
  310.  
  311.  
  312. LICENSE
  313.  
  314. You, the user, have a license to use this program for 30 days after
  315. receiving the executables. After this trial period, you must register
  316. the program with SlugSoft (see below). You also have a license to copy
  317. and share the program freely as long as the package is shared in its
  318. entirety and no more than $10US is ever charged for its distribution.
  319. This program may not be packaged with any other program without express
  320. written permission from the author.
  321.  
  322.  
  323. DISCLAIMER
  324.  
  325. SlugSoft and Chris Jantzen disclaim all warranties as to this software,
  326. whether express or implied, including without limitation any warranties
  327. of merchantability, fitness for a particular purpose, functionality or
  328. data integrity or protection. If it damages your hardware or data in
  329. any fashion, we are not responsible in any way.
  330.  
  331.  
  332. REGISTRATION
  333.  
  334. Registration is nice and easy, so PLEASE DON'T SKIP OVER THIS SECTION!
  335. To register this program, just send me a letter (optional) enclosing a
  336. postcard very clearly stating your name, address, and the current
  337. version you are using. That's it! It would also be nice if you wrote
  338. about how the weather is where you're writing from, how much you like
  339. the program, new features you might like to see in the program, and
  340. other nice things.
  341.  
  342. If you are using this program in a commercial, government, or
  343. educational environment, I would like to restate that I am not
  344. responsible for what this program does on your machine (although I will
  345. try to help if it doesn't seem to work right). I would also like to ask
  346. that along with your letter you send some information, brochures, etc.
  347. on what your company/department/institution does. I cannot help you if
  348. you need help with special paperwork (such as P.O.'s). I would also
  349. respectfully ask that you send me one of your company's/agency's
  350. products.
  351.  
  352. Note, however, that although I don't actually ask for anything for
  353. registration, you won't actually really receive anything for your
  354. registration. You will, however, feel good about yourself, and if you
  355. send a self-addressed, stamped envelope (with enough postage from the
  356. USA to wherever you are) with your letter, I'll send some some heartfelt
  357. thanks as well as respond to any concerns you brought up in your letter.
  358.  
  359. All donations and gifts joyfully accepted.
  360.  
  361.  
  362. OTHER COPYRIGHTS, TRADEMARKS, AND PATENTS
  363.  
  364. References to programs other than ECOPY and other SlugSoft programs
  365. without their respective copyright, trademark, or patent notices are not
  366. meant to be construed as challenges to such programs' copyright,
  367. trademark, and/or patent statuses.
  368.