home *** CD-ROM | disk | FTP | other *** search
INI File | 1991-12-01 | 23.4 KB | 534 lines |
- Sun 1-December-1991
-
- About TSUTIL in General (All rights reserved)
- =======================
-
- This package may be used and distributed freely for NON-COMMERCIAL,
- NON-INSTITUTIONAL, PRIVATE purposes, provided it is not changed in
- any way. (Repacking with another method, is ok though.) For ANY
- other usage, such as use in a business enterprise or at a
- university, contact the author for registration. Uploading to
- bulletin boards is encouraged. Please do not distribute any part of
- this package separately.
-
- The programs are under development. Comments and contacts are
- solicited. If you have any questions, please do not hesitate to use
- electronic mail for communication.
- InterNet address: ts@chyde.uwasa.fi (preferred)
- Bitnet address: SALMI@FINFUN.BITNET
- Funet address: GADO::SALMI
-
- The author shall not be liable to the user for any direct, indirect
- or consequential loss arising from the use of, or inability to use,
- any program or file howsoever caused. No warranty is given that the
- programs will work under all circumstances.
-
- Timo Salmi
- Professor of Accounting and Business Finance
- School of Business Studies, University of Vaasa
- P.O. BOX 297, SF-65101 Vaasa, Finland
-
- CONTENTS:
-
- 1. Summary
- 2. Program Abstracts
-
-
- Timo Salmi UTILities, release 3.5 (TSUTIL35) includes the following
- * * **** * *
- utility-type programs. There are more utilities in packages TSUTLB,
- TSUTLC, TSUTLD, and TSUTLE available separately for example by
- anonymous FTP from garbo.uwasa.fi archives.
-
-
- 1. SUMMARY
-
- TSUTIL35 Utilities 1st collection T.Salmi
- Filename Comment
- -------- --------------------------------
- DAY.EXE Gives a date in a weekday-format
- DIRD.EXE Directories, different files
- DIRS.EXE Directories, same files
- DIRW.EXE As dir/w, recursive, file status
- DTETIM.EXE Displays current date and time
- DTETIMAL.EXE Check system clock from autoexec
- GRAPINFO.EXE Detects your graphics hardware
- PVMKLO.EXE Current date and time in Finnish
- PVMKLOHL.EXE Check system clock in Finnish
- RESET.EXE Resets 80 column text mode
- STACK.EXE Tells available free memory
- SYSINFO.EXE Information about your gadget
- TIMDIF.EXE Difference between two times
- TIMELOG.EXE For logging program usage
- TSPROG.INF List of PD programs from T.Salmi
- TSUTIL.INF Document
- TSUTIL.NWS News announcements about tsutil
- VAASA.INF Info: Finland, Vaasa, U of Vaasa
- ---- ------ ------ -----
-
-
- 2. PROGRAM ABSTRACTS
-
- DAY.EXE (Ver 1.3) Gives a date in a weekday-format
- =================
-
- Usage: DAY date [format]
-
- This utility converts a date into a weekday-date format. The date
- is given with the program call. E.g. DAY 06/07/88 will result in
- We060788. Each component of the date must be two characters, no
- more, no less.
- The day/month/year can alternatively be separated by a hyphen (-)
- or by a point (.), or the date can be concatenated as ddmmyy.
- The date can be also given as month/day/year by giving 1 as the
- second parameter. E.g. DAY 07/06/88 1 will result in We060788. The
- default value of the second parameter is 0.
- The format options are:
- day/month/year 0 or ddmmyy 0
- month/day/year 1 or mmddyy 1
- year/month/day 2 or yymmdd 2
- Years 80-99 correspond to 1980-1999 while 00-79 indicate 2000-2079
- in accordance with the conventions of MS-DOS.
-
- Release notes
- Version 1.2: First, some technical background. Using the Turbo
- Pascal direct screen write routines (the Ctr unit) causes problems
- in PCs with poor compatibility. After having reports of some of my
- programs not working on unconventional PC, I have decided bypass Crt
- where not necessary for the programs functionality. DAY.EXE is one
- of these programs and now uses conventional writes through MsDos
- instead of writing directly to the video memory. This has the added
- advantage of making output redirection possible. Second, giving
- dates as, for example, 1-7-89 instead of 01-07-89 should no more
- cause problems. Thirdly, the code has been made somewhat more
- concise thus reducing the program size.
- Version 1.3: Minor stylistic changes.
-
-
- DIRD.EXE (Ver. 1.5) Directories, different files
- ===================
-
- A new addition first appearing in TSUTIL18.ARC. Compares two
- directories finding out which of the file names (and subdirectory
- names) appear in the first directory, but not in the second.
- Usage: DIRD <first path> <second path>.
- The path names follow the same conventions as DIRW.EXE (Ver. 1.2).
- (See below.)
- For example, if you wish to know which file names appear on the
- device in drive A: but not in B: use "DIRD A: B:". If you wish to
- compare subdirectories SUBDIR1 and SUBDIR2 use "DIRD SUBDIR1\
- SUBDIR2\".
- ┌─────────────────────────────────────────────────────────────┐
- │ Important: NOTICE THE TERMINATING SLASHES, lest subdir1 and │
- │ subdir2 be taken as file, not directory, names. This is a │
- │ deviation from MsDos. │
- └─────────────────────────────────────────────────────────────┘
- DIRD.EXE includes the hidden files in the comparison.
- Furthermore, it shows the file status of the files (hidden,
- read-only, directory).
- The paths may contain file definitions. E.g. "DIRD *.PAS
- C:\*.PAS" is valid, and only compares names ending with .PAS.
-
- Release notes: In version 1.3 the new usage is
-
- DIRD FirstPath\ [SecondPath\]
- [/i(gnore the file-directory distinction)]
- or: DIRD /h(elp)
-
- Files and directories are considered distinct. Therefore, if a file
- and a directory have the same name, the file (or the directory) is
- listed as a difference, unless the /i parameter is on. The /i
- parameter has been added in release 1.3.
-
- Hint: If you want a really good directory comparison program, get
- Michael Mefford's DIRMATCH utility from PC-Magazine's utilities
- (autumn 1989). Available by anonymous ftp from garbo.uwasa.fi as
- /pc/pd2/dirmat20.zip, or from well-stocked BBSes.
-
- More release notes: Version 1.5: Search masks like C:\SUBDIR and
- C:\SUBDIR\ are now identical.
-
-
- DIRS.EXE (Ver. 1.5) Directories, same files
- ===================
-
- Old usage: DIRS <first path\> <second path\>
-
- As DIRD.EXE, but finds out which file names appear in both
- directories. The file attributes (if different) are taken from the
- first directory. DIRS.EXE (and DIRD.EXE) are based on file names.
- They do not compare file sizes, nor file dates. (For a detailed
- comparison of two files use e.g. FILEDIFF.EXE from TSF2CM package.)
-
- Release notes: In version 1.3 the program has been completely
- rewritten. The new description is given below.
-
- Usage: DIRS FirstPath\ [SecondPath\]
- [/m(ark date-size differences)]
- [/i(gnore the file-directory distinction)]
- or: DIRS /h(elp)
-
- This program shows which same file (or subdirectory) names appear in
- two directories. Wildcards are allowed. The files can optionally be
- compared for date stamp and size (/m parameter). If either differs,
- a * is used to mark the fact, when /m is on. Files and directories
- are considered distinct. Therefore, if a file and a directory have
- the same name, this is not shown, unless the /i parameter is on. The
- /m and /i parameters cannot be used at the same time.
-
- More release notes: Version 1.5: Search masks like C:\SUBDIR and
- C:\SUBDIR\ are now identical.
-
-
- DIRW.EXE (Ver. 1.10) As dir/w, but shows subdirectories and file status
- ====================
-
- Usage: DIRW [DirectoryMask] [/s]
- │
- also subdirectories ─┘
-
- ┌───────────────────────────────────────────────────────────────────┐
- │ Hint: I use the following batch at regular intervals to catalogue │
- │ the contents of my harddisk. The ds and dirw programs are at my │
- │ path: │
- │ c: │
- │ cd \ │
- │ ds en /s (ds is Norton's old directory sort) │
- │ del c:\direc\c.dir │
- │ dirw /s >> c:\direc\c.dir │
- └───────────────────────────────────────────────────────────────────┘
- DIRectory Wide command displays the directory in a format similar
- to MS-DOS dir/w command. However, DIRW also displays the hidden
- files as well as shows the status of the files (d=directory,
- h=hidden, r=read-only). (The status of the archive bit is not
- shown.)
- Another difference compared to dir/w is that the file name and
- the extension are separated by a point, not a tab. Thus e.g. you
- would get DIRW.EXE rather than DIRW EXE. This makes a difference
- e.g. when you direct the directories to a file, and wish to search
- for a specific file name.
- You might skip from here directly to the relase notes. DIRW
- requires a stricter syntax of file names than dir/w. If you make a
- mistake, DIRW shows you examples of the correct syntax. The main
- rule is that you should either use no parameter, or enter the
- device, path, and file names, all explicitly.
- Examples of acceptable commands are:
- DIRW
- DIRW A:
- DIRW A:\*.PAS
- DIRW A:\SUBDIR\*.EXE
- also DIRW *.* is acceptable.
- Notice that if you use a subdirectory name, you must precede it
- with the backslash \. Thus e.g. DIRW A:SUBDIR\*.* is not acceptable.
- Neither is DIRW A:\SUBDIR since it lacks the file definition.
- Furthermore, DIRW does not support the ..\ back-reference. Device
- names from A: to F: are accepted. (If this is insufficient, contact
- the author by echomail, as advised at the beginning of this
- document.)
- Those of you who have programs from TSFCOM15 package (or later)
- will notice that the directory option in those programs applies the
- same syntax as DIRW.
-
- Release notes for DIRW.EXE:
- Version 1.2 DIRW has been substantially rewritten for a more
- relaxed syntax. The command now accepts practically the same file
- definitions as does the MS-DOS dir/w command. Thus you can have (in
- addition to the previous examples) e.g.
- DIRW ..
- DIRW SUBDIR (Shows entries named subdir in the CURRENT directory!)
- DIRW SUBDIR\ (Shows entries in subdirectory subdir)
- DIRW A:SUBDIR\
- DIRW SUBDIR\*.EXE
- DIRW ..\SUBDIR\*.*
- and so on.
- Unlike the MsDos dir/w command, DIRW can handle the wildcards * and
- ? also in directory names. Therefore DIRW SUBDIR and DIRW SUBDIR\
- will (contrary to dir/w) show you different informations. The former
- will show if your default directory has a subdirectory named SUBDIR
- while the latter shows the contents of SUBDIR.
-
- More release notes: Since version 1.3 of DIRW and versions 1.1 of
- DIRD and DIRS, the reference by . to the current directory is valid.
-
- In version 1.4 of DIRW and versions 1.2 of DIRD and DIRS the bug
- preventing the use of device names beyond H: has been corrected.
-
- In version 1.5 of DIRW the code has been completely rewritten for
- making it more than 2K smaller. Most importantly, optional switch /s
- has been added to view all subdirectories. Thirdly, if you choose
- other (e.g. B:) than the default drive, DIRW B: will correctly start
- from its current default directory like MS-DOS DIR does.
-
- In version 1.6 corrected a bug that made dirw list a wrong
- directory under special circumstances.
-
- In version 1.7 added switch /a to show allocated bytes, that is
- the space taken up by the listed files. Also added switch /f to go
- with /a. Normally, dirw shows free space on the device unless the /a
- switch is used. Switch /f augments the usual free space information
- if /a has been used (this giving two lines of summary information).
-
- In version 1.8 have changed the summary format again and omitted
- the /a and /f switchews which regulated the format of the summary.
- It is now uniform.
-
- In version 1.9 the search masks like C:\SUBDIR and C:\SUBDIR\ are
- now identical which brings additional compatibility with the MsDos
- DIR /W command.
-
- In version 1.10 Corrected a bug in the recursive option which
- caused problems when recursion started from a subdirectory given as
- a parameter to DIRW.EXE.
-
-
-
- DTETIM.EXE (Ver. 1.3) Displays current date and time
- ==========
-
- Usage: DTETIM [/s(hort version)]
- or DTETIM ?
-
- DaTE and TIMe displays the current date including the name of the
- weekday and the name of the month. This command is useful e.g. in
- autoexec.bat if you quickly just wish to check whether your system
- clock is set right.
- Release notes: Version 1.3: The program now also display the week
- number and the day number of the current date. If you want to omit
- them, use the /s switch. The week number algorithm was kindly
- written for me by Seppo Pynnönen, Ph.D, University of Vaasa.
-
-
- DTETIMAL.EXE (1.4) Check system clock from autoexec
- ============
-
- Usage: DTETIMAL {year as yy or yyyy} [/s(uppress selftest)]
-
- ┌──────────────────────────────────────────────────────────────┐
- │ Hint: This program is more useful that you may think. It is │
- │ advisable to put it in your autoexec.bat. Usually it is │
- │ unobtrusive, but it once saved me from considerable grief by │
- │ detecting that my system clock had got confused by another │
- │ program which crashed my machine. │
- └──────────────────────────────────────────────────────────────┘
- As DTETIM but takes year as a parameter, and compares it to the
- system clock year. If your system clock has a tendency get confused
- for some reason or another, it is useful to include a command such
- as DTETIMAL 1990 in your autoexec.bat. An alarm draws your attention
- to the discrepancy if your system clock year has changed, which
- usually is the case when the system clock gets confused.
-
- Release notes: Version 1.1: The double linefeed after the command
- has been corrected.
-
- Version 1.2: The alarm has been made to sound longer, and output
- redirection has been made possible.
-
- Version 1.3: The program now also displays the week number and
- the day number of the current date. - The alarm has been made more
- persistent.
-
- Version 1.4: Turbo Pascal Crt has been replaced by my own
- routines within the program making it (hopefully) more compatible. -
- A triple selftest against viruses and other tampering has been
- included. The selftest is based on a checksum, filedate and
- filesize. The selftest can be turned off using switch /s. - BTW, if
- you are interested in selftesting Turbo Pascal programs get my
- TSPA26##.ARC (or whichever is the current version) (## = 40, 50, 55,
- or 60) package of Turbo Pascal units.
-
-
- GRAPINFO.EXE (no version number) Detects your graphics hardware
- ============
-
- Detects which graphics hardware you have on your machine. Graphics
- hardware detection is now also available in SYSINFO.EXE.
- Release notes: With the advent of Turbo Pascal 5.0 the detection
- if IBM8514 graphics has been augmented in grapinfo.
-
-
- PVMKLO.EXE (1.3) Current date and time in Finnish
- ==========
-
- PäiVäMäärä and KelLO is the same as DTETIM.EXE, but the weekday and
- the month are in Finnish, the universal major global all-around
- language.
-
-
- PVMKLOHL.EXE (1.3) Check system clock in Finnish
- ============
-
- Same as the old DTETIMAL version 1.3. In Finnish.
- ^^^
-
- RESET.EXE Resets 80 column text mode
- =========
-
- A simple Turbo Pascal program which resets the 80 column text mode.
- Useful after graphics and other such programs leaving the screen in
- a funny state. (Reset.exe is needed in some of my other program
- packages).
-
-
- SCOPY.BAT Copy a file with a single device (Has been moved to
- ========= TSBAT##.ARC)
-
- Occasionally there are situations when you want to copy one file
- from a disk (or a diskette) to another, and you only have a single
- drive available. One method of doing this is first copying the file
- to ramdisk (or hard disk, if available), change the disk, and then
- copy the file back to the new disk, and delete the file from the
- temporary device. SCOPY.BAT automates this procedure. To use SCOPY
- you must have a drive D: (e.g. a ramdisk). To proceed just apply
- SCOPY <file name>. (SCOPY makes a temporary directory d:\tmp for the
- duration of the copying, and removes it afterwards.) A couple of
- rules must be observed: 1) You must NOT use paths! 2) Be careful if
- you use subdirectory names. SCOPY.BAT is a new addition to TSUTIL
- package, first appearing in release 2.0.
- Release notes: In TSUTIL26 package a couple of advice lines have
- been added. And remember not, that is NOT, to use path nor device
- names with scopy.
-
-
- STACK.EXE (Ver 1.2) Tells available free memory as TP sees it.
- ===================
-
- Shows the available free memory. (To be exact, shows the size of the
- largest available free block of memory in the heap, at runtime of
- stack.exe.) Such information can be useful for several special
- purposes. Most importantly, you can establish what happens to the
- largest contiguous block in the stack if you introduce a ramdisk, or
- install resident programs. Since there are several PD ramdisk
- utilities around, you can, for example, see if they can release
- stack, and heap when their size is toned down, and so on. - This
- program really should have been called HEAP rather than STACK.
-
- Release notes: Version 1.1 adds up the largest contiguous block
- available and the memory required by STACK.EXE to give the available
- memory. Earlier, the figure reported was the largest contiguous
- block alone.
-
- Version 1.2: The free memory should now be given accurately, and
- tallies with what standard memory mappers give. The memory
- assessment is based on the information extracted from the PSP
- (program segment prefix) of stack.exe.
-
-
- SYSINFO (Ver. 2.3) Information about your gadget
- ==================
-
- Gives information about your gadget and it's environment. In
- versions earlier than 1.2 there was a bug (relating to memory
- addresses) preventing the use of the program in AT PCs. This has
- (hopefully) been corrected. - Another bug, occasionally preventing
- finding out the default directory, has been corrected in version
- 1.3. (This bug was caused by the slight incompatibility between
- Turbo Pascal 3 and 4.) Further bugs may well remain, since PC
- compatibility is not at its best in the interrupt routines, which
- this kind of a program has to use.
-
- In version 1.4, another compatibility problem occurring in
- certain PC AT machines has been solved.
-
- In version 1.5 graphics hardware detection has been added.
-
- In version 1.6 the program and its routines have been completely
- rewritten. The main sources of information have been Norton &
- Wilton: The New Peter Norton Programmers Guide to the PC & PS/2;
- Jamsa & Nameroff, Turbo Pascal Programmer's Library 2nd ed.; and
- Turbo Pascal 5.0 Reference Guide.
-
- Version 1.7: The Crt unit of Turbo Pascal is no longer used by
- SYSINFO. This is because using the Turbo Pascal direct screen write
- routines (the Crt unit) causes problems in PCs with poor
- compatibility, and I wanted top avoid this problem. - The problem
- with PCs having only one disk drive have been seen to. - The date is
- given with more information. - The information on the drives now
- includes the cluster size. As you probably know, for each device
- this is the smallest number of bytes that will be allocated at any
- one time. For example, if your device uses a cluster size of 1024
- bytes, a file of 1567 bytes takes up 2048 bytes. - Added a simple
- arithmetic speed index. - Truncates overly long path information so
- that the screen does not get muddled.
-
- Version 1.8: The original screen is restored after the program.
-
- Version 1.9: More system information has been included. - The
- program also performs a simple selftest against tampering and
- viruses before running. The selftest checks the file size and date.
-
- Version 2.0: A complete rewrite. See TSUTIL.NWS section Wed
- 20-Feb-91 for the details.
-
- Version 2.1: Some minor improvements. See TSUTIL.NWS 21-Jul-91.
-
- Version 2.2: Made compatible with MsDos 5.0.
-
- Version 2.3: Added mouse detection. EEEEK!
-
-
- TIMDIF (Ver. 1.3) Difference between two times
- =================
-
- Is a new addition to this archive first appearing in TSUTIL17.ARC.
- The utility calculates the difference between two times. The times
- are given with the program call. The earlier time should be given
- first. E.g. TIFDIF 09:12:16 11:07:22 will result in 01:55:06. If the
- first time is greater that the second, it is assumed that the day
- has changed. Thus e.g. TIFDIF 23:44:17 02:05:11 will result in
- 02:20:54. The hours:minutes:seconds can alternatively be separated
- by a point (.) or by a comma (,). Another potential use of TIFDIF is
- converting seconds into the standard time format. Thus e.g. TIFDIF 0
- 23456 will result in 06:30:56. Apply TIFDIF ? for help (i.e. the
- text appearing here).
- There is a similar program for calculating the difference between
- two dates in the tsutlc package.
-
- Release notes: In version 1.2 the name of this program has been
- changed from TIMED.EXE to TIMDIF.EXE. - TIFDIF.EXE no longer
- utilizes the Crt unit. Please see the release notes for DAY.EXE
- version 1.2 for details. This makes output redirection possible, and
- should make the program work also in poorly compatible PCs.
-
- Version 1.3: Minor stylistic changes.
-
-
- TIMELOG (Ver. 1.1) For logging program usage
- ==================
-
- Is a new addition to this archive first appearing in TSUTIL20.
- Usage: TIMELOG your text >>path\program.log
- program call
- TIMELOG >>path\program.log
- Timelog is a program that can be used for keeping a log of your
- calls of other programs. Say, for example, that you want to log your
- usage of program.exe. What you do is give the commands shown above
- (you may want to put them in a .bat batch file).
- The output in program.log will be something like:
- Testing Sa130888 10:59:28 10:59:47
- Testing again Sa130888 10:59:58 11:00:19
- depending on the text you give in the first call.
-
- The elapsed times are not present, but they can be augmented by
- applying a separate program PCPFON.EXE on program.log. It is
- available in TSPFON##.ARC.
-
- Technical notes: Timelog has two modes:
- 1) Text-mode: Invoked when there is text in the call. Skips to a new
- line, and writes the text, the date and the time.
- 2) Time-mode: Invoked when there is no text in the call. Stays on
- the same line, and writes the time.
- Thus no harm (other than forgoing the possibility of calculating the
- elapsed time) is caused if you forget the terminating timelog call.
- (Version 1.0 confused the lines in that case.)
-
- For an example of the usage in a batch file see MSZ.BAT in the
- TSKERM##.ARC package available separately.
-
- You should notice that if you edit the program.log file, editors
- tend to augment an ascii 26 at the end of of the file. This means
- that any new lines added by timelog |text| >>program.log will not be
- visible e.g. if you give the MsDos command "type program.log". This
- is a feature (and a problem) of MsDos, not the timelog.exe program.
- (An advanced user can circumvent this problem by a clever use of
- filters.)
-