home *** CD-ROM | disk | FTP | other *** search
Text File | 1992-07-15 | 72.6 KB | 2,243 lines |
-
-
-
-
-
-
-
-
-
-
- SHAREWARE INSTALLATION SYSTEM LITE
-
-
- Version 2.2
-
-
- (C) 1992
-
-
- by Scanlon Enterprises
-
-
-
-
-
-
-
-
- The Shareware Concept :
-
- The shareware concept has made it possible for you to obtain
- extremely powerful software at a price you can afford, and it
- gives you the opportunity to try the software before you buy.
-
- Shareware is kept alive by your support, Thank you !
-
-
-
- For Comments and / or suggestions, please contact
-
- SCANLON ENTERPRISES
- 38354 17TH ST. E.
- PALMDALE, CA 93550
-
-
-
- Emergency problems, call (805) 272-4827
-
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 2
-
- Shareware Installation System Lite, will be referred to as SIS
- from this point on.
-
- This product is designed to aid the Author / developer in making
- their software easy to install. This product uses the command
- file approach to installation ease. By this, we mean, that the
- Author or developer creates an installation command file, which
- is read in by this product for later recall.
-
- The user or client, starts the installation process by entering
- the new product name, such as INSTALL from a DOS prompt.
-
- The Author or developer, initializes a new installation program,
- by entering the product name, followed by the command line
- switch, of '/I'. The 'I' may be either upper or lower case. Once
- the Author or developer starts SIS, SIS will prompt for a new
- command file, a new password (this protects the Authors command
- set from being changed after installation) and a new file name
- (which may be the same as the previous). Passwords are limited to
- 16 characters, upper and lower case (even spaces).
-
- When the user or Client starts SIS, they will be prompted, based
- upon the Author or developer commands installed at the time. In
- this manner, the Author or developer retains full control of the
- installation process.
-
- The product name upon shipping is SISLITE (with a COM extension).
- All variations of this product will carry a 'COM' extension.
- Because of this extension and file type, no SIS product can be
- larger than 64K total (after adding you installation commands).
- This really is NOT a problem, since a typical command file is
- less than than 5K (typically less than 1K). The size of SIS
- without commands is under 10K, thus leaving room for up to 54K in
- commands ! That's a whole lot of commands.
-
- SIS comes with a password of SISLITE (all uppercase). SIS knows
- the difference between upper and lower case on passwords.
-
- The remainder of this documentation will be devoted to explaining
- usage of the commands and variables which are available for
- commands in the command file. Any command which is NOT a command
- of SIS, must be a DOS program, not a batch file command. Thus,
- ECHO is not allowed, but FORMAT is !
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 3
-
- QUICK START USAGE
-
-
- Create your master disk(s) and save room on disk one for SIS,
- which is about 10K (usually less than 7K) . Now, using any Text
- Editor or Wordprocessor, create the command list, using the
- special commands of SIS and any valid DOS program (executables
- with the extension COM and EXE).
-
-
- A typical command file will contain :
-
- 1) Opening screen describing your product in brief and the base
- requirements of the product.
-
- 2) A prompt to Abort or continue.
-
- 3) Next, prompt for the destination drive.
-
- 4) Prompt for the destination path
-
- You are now ready to copy files from the source drive (you don't
- have to ask for the name, as SIS automatically knows).
-
- 5) Copy files from the source to the destination.
-
- 6) Unpack any files using your un-packing program or using a
- command to start a self un-packing program.
-
- 7) Start any new program, or display a closing screen giving the
- user quick start instructions.
-
-
- The next step is to type SISLITE /I at any DOS command line
- prompt. This will be the process of applying your commands to a
- new installation file. You will be prompted for the existing
- password (SISLITE is the original one), for verification to
- proceed on deleting the existing command set, the new command
- file (path may be included), the name of the new installation
- program (no extension is required), and finally the new password,
- so others can not modify your command list.
-
- Your new installation program will be created. You must copy this
- to your new master disk. Then, you should test it. This is the
- time to find mistakes. If you have the registered version, we
- provide both a Text Editor and a SIS verification system. Our SIS
- verifier will find over 90% of the possible errors. We have
- found, if your installation command set works once, and the user
- has a PC or compatible system running any DOS from 2.0 up, that
- SIS will work as installed each time !
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 4
-
- Quick Start Commands ..
-
- 01) CLR - clears the display
-
- 02) CD - change directory
-
- 03) COPY - copy files from source to destination
-
- 04) CR - waits for ENTER key to be pressed
-
- 05) DELETE - Delete a file
-
- 06) GETDRV - Gets destination drive from user
-
- 07) GOTO - Branch to a label
-
- 08) IFCR - Test last CR entry for escape key
-
- 09) IFDOS - Test DOS version
-
- 10) IFEXIST - Test for existence of a file
-
- 11) IFVID - Test for color system
-
- 12) IFYN - Test response from YN input function
-
- 13) IFERR - Test if an error level is there
-
- 14) LEN - Set the LEN variable to a value from 1 to 80
-
- 15) LIN - Gets up to 80 character line input
-
- 16) LOCATE - Position cursor
-
- 17) MKDIR - Create destination directory
-
- 18) RENAME - Rename a file
-
- 19) ROOT - Sets destination path prefix to always assume path is
- off root.
-
- {continued next page}
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 5
-
- 20) SETCOLR - Set color for CLR function
-
- 21) SETDRV - Set destination drive letter
-
- 22) SETLIN - Set Line input variable
-
- 23) SETPTH - Set path to last LIN (line input)
-
- 24) SETSIZ - Set the target min. size
-
- 25) SETSPTH - Set source path
-
- 26) WRITE - Display text using current colors
-
- 27) YN - Waits for 'Y', 'N' or Escape (upper or lower case) as
- yes no response.
-
- Any other command file entry is a DOS program, such as FORMAT.
-
- In addition, there are a few variables that SIS knows about. To
- use these variables, prefix them with the '@' character.
-
- EXAMPLE : COPY @LIN
-
- The @LIN above will be replaced with whatever is in the current
- line input buffer, from a previous LIN function call.
-
-
- Quick start variables ...
-
- The following is a list of available variables :
-
- 1) DRV - The selected destination drive
-
- 2) PTH - The selected destination path
-
- 3) YN - Current response from the YN function
-
- 4) CR - returns 'E' if escape was pressed at last CR function
-
- 5) COLR - returns the value of the current color setting in HEX
-
- 6) SRC - Returns the source drive
-
- 7) LIN - returns the string input at the last LIN function
-
- 8) SPTH - returns a string equal to the selected source path
-
- Remember, to use these variables on a command line, precede it
- with the '@' character.
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 6
-
- COMMAND FILE
-
-
- This is the file the Author or developer creates, which contains
- the SIS commands and DOS commands. A SIS command file can NOT
- have any BATCH file commands. These are commands which are built
- into DOS. A command other than SIS commands, are the names of COM
- or EXE programs residing on the source disk or the client system,
- with a DOS PATH set to it.
-
-
- This file is merged into SISLITE when SIS is started with the /I
- command line switch.
-
-
- Command file line lengths should be under 120 characters
-
- A command file size can be up to 56K bytes.
-
- The commad file can be created using any word processor (which
- saves files as ascii), any text editor or our LWRITE program.
-
-
- A typical command file might contain the following :
-
-
- CLR 1 1 25 80 17
- LOCATE 5 5
- WRITE INSTALLING THE SHAREWARE INSTALLATION SYSTEM LITE
- LOCATE 7 5
- WRITE ENTER YOUR DESTINATION DRIVE
- GETDRV
- LOCATE 9 5
- WRITE ENTER THE DESTINATION PATH TO INSTALL TO
- CLR 10 5 10 75 07
- LOCATE 10 5
- LIN
- SETPTH
- MKDIR
- COPY *.*
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 7
-
-
- The above would get the destination drive and path, make the
- directory on the destination and finally copy all files on the
- source to the destination.
-
- The user is prompted for both the drive and path. The screen is
- cleared to white on blue (color systems) and just ahead of the
- line input command, LIN, the line input the string at, is cleared
- to white on black.
-
- The above file takes less than 400 bytes ! Also, in this case, we
- do not use any additional commands other than those supplied
- within SIS, thus keeping the total installation system size to a
- small under 8K bytes. The command file itself is NOT included on
- the installation disk, as the commands will reside within the SIS
- installation system itself.
-
- EXTERNAL COMMANDS
-
- An external command must have either a COM or EXE extension, no
- batch files allowed. The line containing an external command,
- must include the full path and name.
-
- IE .... C:\SIS\SIS.COM
- SISLITE.COM
-
- In the above, we are starting the COM program SIS, from the SIS
- directory, on drive C. If the drive letter is NOT included, then
- the file is assumed to be on the current drive, usually the
- source drive of the program to be installed.
-
- An external command may include any command line options which
- are normally passed to the program, such as :
-
- WS.EXE MYFILE
- FORMAT.EXE A:
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 8
-
- SIS Variables :
-
-
- Although all of the variables can be retrieved on the command
- line (of any line in a Command File), the most useful ones are :
-
-
- LIN, DRV & PTH
-
- Your command line will be expanded to include the variable(s)
- which are currently set. In this way, a command line like the
- following will be expanded :
-
- IFEXIST @DRV:@PTH\COMMAND.COM GOTO XIT
-
- If the variable @DRV is 'D' and @PTH is \SIS then the line would
- be expanded to :
-
- IFEXIST D:\SIS\COMMAND.COM GOTO XIT
-
- In this manner, some things can be done, with unknowns at run
- time. This is a very powerful feature.
-
- An example of using the DRV variable follows :
-
- @DRV:
-
- This will set the current drive to that selected by the user
-
- In this way, you will be logged onto the destination drive
-
- We can also change directories by using the CD command :
-
- CD @PTH
-
- This will expand to the current path after the PTH variable is
- set using the SET PTH function. Also, in conjunction, we can also
- specify the drive with this command, so :
-
- CD @DRV:@PTH
-
- Is also perfectly legal
-
-
-
- SIS ERRORLEVELS
-
- SIS will exit with an errorlevel if any major errors are detected
- at run time. See extended documentation below for errorlevels.
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 9
-
-
- - - - U S A G E - - -
-
-
- CLR
-
- Syntax : CLR srow scol erow ecol colr
-
- Where : 'srow' & 'scol' are the starting row / column to clear
- 'erow' & 'ecol' are the ending row / column to clear
- 'colr' is the color to clear the area to in HEX
-
- Alternate : CLR
-
- This version clears the entire display
-
- All of these are decimal values, except 'colr', which is HEX, and
- must be two digits (no more, no less).
-
- 'colr' may also be selected by using the variable @COLR instead
- of a value.
-
- Example : CLR 5 5 20 75 17
-
- The above clears lines 5 thru 20 and columns 5 thru 75 to white
- on blue.
-
- Example : CLR 6 6 20 76 @COLR
-
- Clears lines 6 thru 20 and columns 6 thru 76 to the value of the
- variable @COLR.
-
-
- COPY
-
- Syntax : COPY fname
-
- Where : 'fname' is any valid DOS file name and my include wild
- cards, such as '*' or '?'
-
- Example : COPY SISLITE.COM
-
- Would copy 'SISLITE.COM' from the source to the destination
-
-
- CR
-
- Syntax : CR
-
- Waits for the user to press ENTER or ESCAPE
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 10
-
-
- - - - U S A G E - - -
-
-
-
- GETDRV
-
-
- Syntax : GETDRV
-
- Waits for the user to enter the destination drive letter or the
- ESCAPE KEY.
-
-
- GOTO
-
- Syntax : GOTO label
-
- Where : 'label' is any string beginning with a colon ':'
-
- Example : GOTO XIT
-
- Would look for the label ':XIT'
-
-
-
- IFCR
-
- Syntax : IFCR command
-
- Where : 'command' is any valid command file command
-
-
- Example : IFCR GOTO XIT
-
- This would branch to the label if the last CR operation returned
- an ESCAPE.
-
-
-
- IFDOS
-
- Syntax : IFDOS ver command
-
- Where : 'ver' is the version to test for, and the condition is
- met, if the actual DOS version is greater than or equal to 'ver'
-
- 'command' is any valid Command File command
-
- Example : IFDOS 2.0 THEN GOTO GOODOS
-
- Would branch the file to the label 'GOODOS' if the actual DOS
- version was 2.0 and up (IE.. 3.0 would branch.)
-
-
-
-
-
- Shareware Installation System Lite PAGE 11
-
-
- - - - U S A G E - - -
-
-
-
- IFEXIST
-
- Syntax : IFEXIST fname command
-
- Where : 'fname' is any valid DOS file name
- 'command' is any valid Command File command
-
- Example : IFEXIST SISLITE.COM GOTO XIT
-
- Branches if the file 'SISLITE.COM' exists, to the label 'XIT'
-
-
-
- IFVID
-
- Tests if current video is color
-
- Syntax : IFVID command
-
- Where : 'command' is any valid Command File command
-
- Example : IFVID GOTO COLOR
-
- Branches to 'COLOR' if the video system in use is color
-
-
-
- IFYN
-
- Syntax : IFYN resp command
-
- Where : 'resp' is the expected YN response being tested for, and
- may be either 'Y', 'N' or 'E', where 'E' is for escape.
-
- 'command' is any valid Command File command
-
-
- Example : IFYN Y GOTO DOYES
-
- Would branch to 'DOYES' if the last YN operation returned a
- response of 'Y' (for yes).
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 12
-
-
- - - - U S A G E - - -
-
-
-
- IFERR
-
- Syntax : IFERR var command
-
- Where : 'var' is the expected errorlevel
- 'command' is any valid command file command
-
- The command 'command', will be performed, if ERR is equal to or
- greater than the selected test 'val'.
-
-
-
- LIN
-
- Syntax : LIN
-
- Gets up to 80 characters as input from the user
-
- This input can be set to the PTH by using SET PTH command
-
-
-
-
- LOCATE
-
- Syntax : LOCATE row column
-
- Where : 'row' and 'column' are decimal values representing the
- new cursor location of row and column.
-
-
- Example : LOCATE 5 5
-
- Would position the cursor to line 5 column 5
-
-
- MKDIR
-
- Syntax : MKDIR
-
- Creates the destination directory set with the SET PTH function
-
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 13
-
-
- - - - U S A G E - - -
-
-
-
- SETCOLR
-
- Syntax : SETCOLR foreground background
-
- Where : 'foreground' is the foreground color to use
- 'background' is the background color to use
-
- Both values are in decimal, in the range of 0 thru 16
-
- See COLORS below for the standard set of colors available.
-
- This puts the combined value into the variable 'COLR' for later
- use with the @COLR variable. This is useful if you don't want to
- calculate the HEX value for the CLR function above.
-
-
-
- SETPTH
-
- Syntax : SETPTH
-
- Sets the variable PTH to the last LIN operation value.
-
-
-
- WRITE
-
- Syntax : WRITE text
-
- Where : 'text' is any string of characters.
-
- This displays the selected text at the current cursor location,
- using the existing colors.
-
- Example : WRITE Hello
-
- Displays 'Hello' at the current cursor location
-
-
-
- YN
-
- Syntax : YN
-
- Waits for the user to press 'Y', 'N' or the Escape key. 'Y' & 'N'
- may be upper or lower case, typed characters.
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 14
-
-
- - - - U S A G E - - -
-
-
-
- CD
-
- Syntax : CD dir
-
- Where : 'dir' is the name of a directory to change to
-
- Example : CD \SIS
-
- Would change the current directory to SIS off the root
-
-
-
- SETDRV
-
- Syntax : SETDRV d
-
- Where : 'd' is the desired drive for a default
-
- Example : SETDRV C
-
- Sets the default destination drive to C
-
-
-
- SETSPTH
-
- Syntax : SETSPTH string
-
- Where : 'string' is any valid path string
-
- This sets the current source path for the COPY command. The
- default source path is the root.
-
-
- SETLIN
-
- Syntax : SETLIN text
-
- Where : 'text' is any string of characters
-
- This is useful for setting a default destination path, in
- conjunction with the above SET PTH function.
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 15
-
- - - - U S A G E - - -
-
-
- LEN
-
- Syntax : LEN n
-
- Where : 'n' is a decimal value, range of 1 thru 80
-
- This fixes the max length for the LIN function (above). The
- default LIN input length is 80 characters.
-
-
-
-
- ROOT
-
- Syntax : ROOT
-
- After executing this command all subsquent SET PTH commands will
- assure the path is prefixed with the "\" character, so all paths
- will be relative to the root.
-
-
-
- DELETE
-
- Deletes a single file
-
- Syntax : DELETE filename
-
- Where : 'filename' is any valid DOS file name and may NOT include
- wild cards "*" or "?"
-
-
-
-
- RENAME
-
- Renames a single file
-
- Syntax : RENAME oldfile newfile
-
- Where : 'oldfile' and 'newfile' are any valid DOS file names and
- may NOT include wild cards "*" or "?" . 'oldfile' is the files
- current name, while 'newfile' is the name to change to.
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 16
-
- - - - U S A G E - - -
-
-
- SETSIZ
-
- Syntax : SETSIZ bytes
-
- Where : 'bytes' is a decimal value of less than 4 gigabytes
-
- Default value for SETSIZ is 360000 (360K)
-
- This sets the expected drive size minimum, IE...360000 bytes
- means that there must be at least 360K available on the selected
- drive.
-
- An errorleve is set (ERR) upon end users entry from the GETDRV
- function. EXAMPLE:
-
- SETSIZ 363000
- WRITE ENTER DESTINATION DRIVE >_
- GETDRV
- IFERR 1 GOTO BADDRV
- IFERR 2 GOTO BADSIZ
-
- ERR = 1 if the drive is bad (selects a drive that is NOT
- available), ERR = 2 if the drive does NOT have the requested min.
- size set by SETSIZ, above is 363000
-
-
- The variable SPTH (@SPTH) can be used with the CD function to
- allow changing the path on the source drive.
-
-
- Any other string of characters starting a line will be assumed to
- be a valid file name, except labels (beginning with a colon).
- Remember, NO batch commands such as ECHO, CD, MD, etc.. are
- allowed in the commands used.
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 17
-
- SIS COLORS
-
-
- The colors available for the SIS commands must be in the range of
- 0 thru 16 (exclusively), for foreground and background. For
- entering colors as HEX (both values are combined), the colors
- range from 0 thru F (IE... 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F)
-
- When used with the CLR command, both values are entered as a
- combined value, with the background first. (IE... 17 would be 1
- for background and 7 for foreground)
-
- For background colors, any value over 7, makes the foreground
- color blink. IE... 87 would be 17 plus, the foreground color 7
- would blink.
-
- COLOR TRANSLATION
-
-
- Foreground and background Foreground only
-
- 0 = Black 8 = Dark Gray
- 1 = Blue 9 = Light Blue
- 2 = Green 10 = Light Green
- 3 = Cyan 11 = Light Cyan
- 4 = Red 12 = Light Red
- 5 = Magenta 13 = Light Magenta
- 6 = Brown 14 = Yellow
- 7 = White (gray) 15 = White (intense white)
-
-
- Where : 10 = 0A Hex 11 = 0B Hex
- 12 = 0C Hex 13 = 0D Hex
- 14 = 0E Hex 15 = 0F Hex
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 18
-
- SPECIAL NOTES
-
-
- SIS provides some features automatically. One is SIS
- automatically flags the drive which started SIS (the installation
- program) on, as the source drive. This value is stored in the
- variable @SRC for your use. SIS also supplies the destination
- drive once you request that from the client (end user), as well
- as the destination path. The destination drive is supplied as
- variable @DRV while the path is @PTH . SIS supplies on other
- special variable, @VID. This is used with the special IF
- function, of 'IF VID command' to test for a color system. With
- this feature, you can set the colors for the CLR function
- depending upon the video type. A more complete explanation is
- provided below.
-
-
- In the video test above (IF VID) the command 'command' is
- executed only if VID is color. In other words, the command
- supplied, would NOT be executed if VID is monochrome.
-
-
- SIS automatically tests for DOS 2.0 and up, thus if SIS finds a
- system attached, running DOS 1.0, it would stop the install and
- produce an error message.
-
-
- SIS also automatically tries to set the video to 25x80 color, if
- that fails, SIS will check if the system is monochrome, and if so
- continue, or halt if a system is detected not fitting the two
- possible modes.
-
-
- SIS, upon entry, also clears the display. Thus you don't need a
- clear function prior to this.
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 19
-
- EXTENDED DOCUMENTATION - REGISTERED VERSION
-
-
-
- The remainder of this documentation will present information not
- covered by the original Shareware documentation.
-
-
- Preparation :
-
-
- Create a Command File using LWRITE, any wordprocessor or text
- editor. The command file contains the instructions SIS follows to
- provide your software with an installation system. Since SIS
- provides no thinking of its own, the system depends upon your
- Command File being correct. For this reason I have provided you
- with the SISVER program, which reads in a Command File and
- verifies it's syntax. For details on usage and reporting errors
- for SISVER, please read the SISVER.DOC file.
-
-
- Once you have a verified Command File, you can configure SIS by
- entering SISLITE (or your current program name) at a DOS prompt,
- followed by a space and '/I'. IE... 'SISLITE /I'
-
- When you press the ENTER key, after entering the above, you will
- be prompted to verify that indeed you really want to re-configure
- the installation routines.
-
- Upon verifying the above, you will be prompted for the current
- password, which is 'SISLITE' . You enter the password, and press
- ENTER. If you have already configured SIS once, and are
- re-configuring, then enter whatever password you used to save the
- new previous configuration.
-
- You will now be prompted for a new Command File, containing the
- new set of installation commands. Any valid file name and
- extension is valid here. IE.... 'CMD.LST'
-
- Now SIS will prompt for a name to call the new installation
- system. You enter up to 8 characters, SIS supplies the 'COM'
- extension. Two typical file names to use are 'GO' & 'INSTALL',
- however, be creative, and use any 8 character file name.
-
- Finally, you are prompted for a new password. You may enter any
- character, upper or lower case alpha characters are allowed. SIS
- will require exactly the same sequence when an attempt is made to
- change the current configuration / installation commands, using
- the '/I' option.
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 20
-
- After pressing enter (above), you will have a new installation
- system, ready to use (easy !). Copy the new installation program
- thus created to your first master disk (disk to be distributed).
- Now, your customers need only enter the name of the program,
- after logging onto the floppy, and SIS will execute each of the
- commands it found in your Command File.
-
- Starting on page 8 (above), the exact syntax of each available
- command was given, so the remainder of this documentation will be
- used to provide expanded usage explanations.
-
-
- CLR is an easy to use function, and replaces the DOS CLS command,
- with some enhancements. One, you control the area of the display
- to clear and two, you can clear the area to any color. The color
- you specify with CLR must be hex, or the variable @COLR may be
- supplied. @COLR is set when you supply a foreground and
- background color using the SET COLR option, described below.
-
- Although, CLR is NOT a window manager, it can be used in a
- similar fashion. You can clear several areas of the display to
- different colors, thus creating a window effect. When the
- function WRITE is used, to display text, the current screen
- colors are used, thus taking full advantage of any colors set
- using the CLR function.
-
- A typical usage, would be to first clear the entire screen to
- white on blue (color systems), then create a window to display,
- perhaps a menu.
-
- CLR 1 1 25 80 17 {Clears all to white on blue}
- CLR 5 5 15 60 4F {Make a white on red menu}
-
-
- You could also clear four window areas, such as :
-
- CLR 1 1 12 40 17 {Top left to white on blue}
- CLR 1 41 12 80 4F {Top right to white on red}
- CLR 13 1 25 40 30 {Bot left to black on cyan}
- CLR 13 41 25 80 20 {Bot right to black on green}
-
- For monochrome systems the following might be used :
-
- CLR 1 1 12 40 70 {Top left to black on white}
- CLR 1 41 12 80 07 {Top right to white on black}
- CLR 13 1 25 40 0F {Bot left to intense white on
- black}
- CLR 13 41 25 80 70 {Bot right to black on white}
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 21
-
- Of course, once you put information into an area of the screen,
- you can use CLR to re-clear that portion for re-use.
-
-
- Using the SETCOLR function prior to CLR saves you from the HEX
- requirement, as using the SETCOLR creates the HEX value for you,
- when you supply the foreground and background values.
-
- For instance :
-
- SETCOLR 7 1
- CLR 1 1 25 80 @COLR
-
- Will clear the entire screen to white on blue.
-
-
-
- The SIS COPY function is an enhanced version of the DOS COPY
- command. The SIS version does NOT require a destination, as the
- destination is assumed to be the destination supplied by your
- customer, the end user. The source is always constant, and will
- be the drive which SIS started on.
-
- Use COPY to place your original files onto the destination
- system, then use your file extraction program to extract the
- files. Alternately you can extract the files from the source to
- the destination, which will be explained later.
-
- Using COPY :
-
-
- COPY 'source file name'
-
- The 'source file name' is any file name, including wild cards,
- which exist on the source drive. Do NOT specify a directory or
- drive letter, just the 8 character name and 3 character
- extension, such as '*.*', '*.DOC' or 'READ.ME' .
-
-
- GOTO is valuable in that a branch may occur during the sequence
- of instructions to perform during an installation. The GOTO may
- simply be the start of a command, such as 'GOTO XIT' or may be
- used as the command to perform when using one of the IF functions
- supplied with SIS.
-
- The GOTO function is followed by a label name, which is a place
- holder in the command list, similar to that in a batch file. And
- like a batch file label, the label must be preceded by a COLON.
-
- GOTO XIT
- command(s)
- :XIT
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 22
-
-
- Using the previous CLR function, in an example, along with the IF
- VID function we come up with :
-
- SETCOLR 7 1 {Start with white on blue}
- IFVID GOTO GOTCOLOR {If the sys is color bypass
- SETCOLR 7 0 { this line, setting to white
- :GOTCOLOR { on black -- this is the
- { label
-
- We could be more effective by using the following :
-
- SETCOLR 7 0
- IFVID SETCOLR 7 1
-
- Of course, the GOTO is better when we have several commands to
- execute depending upon some condition, such as if the system is
- color on monochrome.
-
-
- When you issue the function 'GETDRV' to have the user input the
- drive to install to, be sure to provide a prompt, such as :
-
- LOCATE 5 5
- WRITE Please enter the drive letter to install to : _
-
- Upon completion of the last line (above), the cursor will be
- positioned as shown, at the end of the display string, which will
- be used as the drive prompt. Then to change to the selected
- drive, simply :
-
- @DRV:
-
- You must provide the colon ":", the drive letter will be supplied
- via the @DRV variable.
-
- You can get back to the source drive by entering :
-
- @SRC:
-
- In this way, you can change between the source and destination
- with ease.
-
- You can use the CR function to have the user decide to abort or
- continue, for example :
-
- LOCATE 5 5
- WRITE Press ENTER to continue, or ESCAPE to abort
- CR
- IFCR GOTO XIT
- other commands
- :XIT
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 23
-
- The previous example would branch to XIT (label) if the user
- pressed the escape key during the CR function. In this manner,
- you can abort the installation process at any time.
-
-
- Does your program like to run under DOS 3.0 and up only ? Then
- use the function 'IFDOS' to make that test, IE....
-
- IFDOS 3.0 GOTO GOOD.DOS
- LOCATE 5 5
- WRITE Must have DOS 3.0 and up ...
- GOTO XIT
- :GOOD.DOS
- commands
- :XIT
-
-
- Your system runs only on DOS 3.0, then use this :
-
- IFDOS 3.1 GOTO BAD.DOS
- IFDOS 3.0 GOTO GOOD.DOS
- :BAD.DOS
- LOCATE 5 5
- WRITE Must have DOS 3.0 !
- GOTO XIT
- :GOOD.DOS
- commands
- :XIT
-
-
- SIS provides the conditional test 'IFEXIST' primarily to give you
- a method to verify the existence of your source files. In this
- manner, you can be sure that the correct disk number is currently
- installed as a source disk, or that the user has NOT started the
- installation from other than the source.
-
- A good example of using the feature is :
-
- :DSK.ONE
- IFEXIST DISK.ONE GOTO VALID.ONE
- LOCATE 5 5
- WRITE Disk one of installation is not source, please
- WRITE install disk one, and press ENTER or
- WRITE press ESCAPE to abort.
- CR
- IFCR GOTO ABRT
- GOTO DSK.ONE
- :ABRT
- LOCATE 7 5
- WRITE Please start installation from the source drive.
- :XIT
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 24
-
- Notice in the above example, the multiple WRITE functions
- following the first LOCATE function. If you want to make long
- lines, using the full 80 columns, please, do use more than one
- WRITE to do it. Remember, WRITE does NOT provide a CR/LF to set
- a new line, and any text not fitting on the current line will be
- truncated (chopped off).
-
- The file we test for, in the above (previous page), may even be
- an empty file (zero bytes). This type of file is often used as a
- flag to mark a disk, as one, two, etc....
-
- Another case to use the IFEXIST function is to verify that a
- directory does not exist. That is, make sure the user is having
- us create a new directory.
-
- IFEXIST @PTH\*.* GOTO BAD.PATH
- commands
- GOTO XIT
- :BAD.PATH
- LOCATE 5 5
- WRITE Invalid path specified, directory exists.
- LOCATE 6 5
- WRITE press ENTER to try another directory name
- WRITE or ESCAPE to abort installation.
- CR
- IFCR GOTO XIT
- GOTO GET.DIR
-
-
- The above example simply tests if any file exists in the
- destination directory. If any file exists, then have the user
- re-specify or do additional testing or abort at that point.
-
- Need to ask the end user a question, such as is there a mouse ?
-
- SIS provides for your needs as follows :
-
- LOCATE 5 5
- WRITE Does your system have a mouse (ESCAPE = abort)
- YN
- IFYN N GOTO NOMOUSE
- IFYN E GOTO ABORT
- COPY MOUSE.*
- :NOMOUSE
- commands
- :ABORT
-
-
- In this example, if the user presses the escape key, he wants to
- abort. A no "N" means no mouse, and yes means copy mouse stuff
- for mouse support.
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 25
-
- SIS provides an errorlevel detection system to replace the DOS IF
- ERRORLEVEL . To use the SIS version, simply replace ERRORLEVEL
- with ERR and write your test as thought it were ERRORLEVEL.
-
- For instance, if you start some program which can exit with an
- errorlevel (for failure), then the following would work.
-
- HELP.EXE
- IFERR 1 GOTO BAD.HELP
- commands
- GOTO XIT
- :BAD.HELP
- LOCATE 5 5
- WRITE Help failed, aborting installation
- :XIT
-
- In this example, if the program HELP.EXE fails, then we abort
- with an exit message.
-
- SIS provides several ERRORLEVELS for your testing, see
- ERRORLEVELS below for details.
-
-
- The SIS Line input function "LIN" is provide to get user
- response, a line at a time, of up to 80 characters. This function
- is commonly used to get the user to specify the destination path
- as in the following :
-
- LOCATE 5 5
- WRITE Enter the destination path :
- LIN
- SETPTH
-
- This example gets input from the user, then sets the path to the
- input, via the 'SETPTH' function.
-
-
- MKDIR
-
- This function is provided so that you can create the named
- directory that the user provides, as in the previous example. To
- use this function, you may do the following :
-
- LOCATE 5 5
- WRITE Enter the destination path :
- LIN
- SETPTH
- MKDIR
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 26
-
- Alternately, prior to creating the directory use :
-
- WRITE Enter the destination path :
- LIN
- SETPTH
- IFEXIST @PTH\*.* GOTO COPY.IT
- MKDIR
- :COPY.IT
-
- This way, you only create the directory if it doesn't exist.
-
-
- The SIS WRITE function makes no attempt to validate your cursor
- position, no the current screen colors. If you have set the
- colors to black on black for instance, then using WRITE will
- produce invisible characters.
-
-
- SIS provides the equivalent DOS command CD (change directory) to
- allow you to log into the destination directory to perform a
- function after installation, such as extracting files. Also, this
- function can be used to change directories on the source disk.
-
- The first example will use CD to aid in extracting files from the
- source disk.
-
- LOCATE 5 5
- WRITE Extracting Documentation
- @DRV:
- CD @PTH
- @SRC:DOCS.EXE
-
- In the above, the file DOCS.EXE is a self extracting file, and
- will extract to the current drive (destination) and path.
-
-
- While the above examples are good, examples, they are not
- complete Command Files. For Command File examples see the files
- CMD01.LST thru CMDnn.LST .
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 27
-
- ERRORLEVELS
-
-
-
- Errorlevels are reported via the variable @ERR and by using the
- IF ERR function, built into SIS.
-
- Using IFERR is very close to using the DOS IF ERRORLEVEL command
- in a batch file.
-
- When using IFERR, you supply an expected value, say 27, then a
- command to perform if the test passes. Errorlevel testing causes
- a PASS when the tested errorlevel (ERR) is equal or greater than
- the expected (test) value.
-
- IE.... IFERR 27 GOTO ABORT
-
- The above passes (branch to the label 'ABORT') would occur if the
- variable ERR was 27 or greater. A better way to test for just an
- errorlevel of 27, would be :
-
- IFERR 28 GOTO BYPASS
- IFERR 27 GOTO ABORT
- :BYPASS
- commands
- :ABORT
-
- Thus, you can see, that errorlevels greater than that desired,
- must first be checked, then the value for which you want to
- perform a separate command.
-
-
- SIS will supply a variety of ERRORLEVELS which can be tested for
- using the IF ERR function (as above), these are :
-
- 0FF - SIS has bombed for some reason, such as a bad installed
- command file.
-
- This error is given in extreme cases where no other recourse
- exists, and results in an exit to DOS... This error is also a
- possible indicator that your installation file has been tampered
- with...
-
-
- 0FE - Empty Command File / Not configured properly
-
- This error only occurs when the developer really goofed. Result
- is that SIS exits, reporting this error code, no installation
- takes place.
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 28
-
- 0FD - Wrong DOS Version
-
- This is only reported at start time, either during a
- configuration attempt or installation attempt. This means the
- user is using DOS 1.x . SIS LITE does NOT support this old DOS
- version...
-
-
- 0FC - Invalid password
-
- This error results in an exit, and possibly indicates an attempt
- at tamper, or the developer forgot the password..
-
-
- 0FB - User Aborted
-
- This error occurs during the configuration process and is caused
- by the developers abort request. Aborting exit is completely
- under the developers control during an install session. An
- installation abort would result in an errorleve of 27 (ERR = 27)
- or errorlevel 3 (ERR = 3) during an install session. When this
- happens, it is the developers responsiblity to make the decision
- on how to exit.
-
-
- 0FA - Error in reading command file
-
- This error results in an exit, indicating this failure, and
- occurs only during a configuration session. This failure
- indicates the command file is bad, or that the file has been
- locked !
-
-
- 0F9 - Command file too large
-
- This error only occurs during a configuration session, and
- indicates that the command file is just too large for SIS LITE to
- handle. File size limit for SIS LITE is 56K (or about), depending
- upon developers base ram size.
-
-
- 0F8 - SIS is lost
-
- This error results in SIS exiting, and is caused by a defecting
- install command, a damaged install file or tampering.
-
-
- 0F7 - Invalid Command Line
-
- This error results in SIS exiting, and is caused by the end user
- trying command line options (tampering).
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 29
-
-
- Other errors occuring at installation time depend upon
- circumstances, such as an installation abort request, where ERR
- is set to 27. Usually, after executing an internal function, such
- as SET??? or WRITE, LOCATE, etc.., the errorlevel is set to one
- for a normal failure, and input routines set the errorlevel to 27
- if the ESCAPE key or ^C key is pressed
-
- During execution of an external program, the errorlevel reported
- will be what that program sets. IE... IF the DOS FORMAT program
- sets the errorlevel at 4, then ERR will be 4 at that time.
-
-
- HEX to decimal translation for ERROR codes :
-
- HEX DEC HEX DEC HEX DEC HEX DEC
- ------------------------------------------------------------
- 0000 0000 0001 0001 0002 0002 0003 0003
- 0004 0004 0005 0005 0006 0006 0007 0007
- 0008 0008 0009 0009 000A 0010 000B 0011
- 000C 0012 000D 0013 000E 0014 000F 0015
- 0010 0016 0011 0017 0012 0018 0013 0019
- 0014 0020 0015 0021 0016 0022 0017 0023
- 0018 0024 0019 0025 001A 0026 001B 0027
- 001C 0028 001D 0029 001E 0030 001F 0031
- 0020 0032 0021 0033 0022 0034 0023 0035
- 0024 0036 0025 0037 0026 0038 0027 0039
- 0028 0040 0029 0041 002A 0042 002B 0043
- 002C 0044 002D 0045 002E 0046 002F 0047
- 0030 0048 0031 0049 0032 0050 0033 0051
- 0034 0052 0035 0053 0036 0054 0037 0055
- 0038 0056 0039 0057 003A 0058 003B 0059
- 003C 0060 003D 0061 003E 0062 003F 0063
- 0040 0064 0041 0065 0042 0066 0043 0067
- 0044 0068 0045 0069 0046 0070 0047 0071
- 0048 0072 0049 0073 004A 0074 004B 0075
- 004C 0076 004D 0077 004E 0078 004F 0079
- 0050 0080 0051 0081 0052 0082 0053 0083
- 0054 0084 0055 0085 0056 0086 0057 0087
- 0058 0088 0059 0089 005A 0090 005B 0091
- 005C 0092 005D 0093 005E 0094 005F 0095
- 0060 0096 0061 0097 0062 0098 0063 0099
- 0064 0100 0065 0101 0066 0102 0067 0103
- 0068 0104 0069 0105 006A 0106 006B 0107
- 006C 0108 006D 0109 006E 0110 006F 0111
- 0070 0112 0071 0113 0072 0114 0073 0115
- 0074 0116 0075 0117 0076 0118 0077 0119
- 0078 0120 0079 0121 007A 0122 007B 0123
- 007C 0124 007D 0125 007E 0126 007F 0127
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 30
-
- HEX DEC HEX DEC HEX DEC HEX DEC
- ------------------------------------------------------------
- 0080 0128 0081 0129 0082 0130 0083 0131
- 0084 0132 0085 0133 0086 0134 0087 0135
- 0088 0136 0089 0137 008A 0138 008B 0139
- 008C 0140 008D 0141 008E 0142 008F 0143
- 0090 0144 0091 0145 0092 0146 0093 0147
- 0094 0148 0095 0149 0096 0150 0097 0151
- 0098 0152 0099 0153 009A 0154 009B 0155
- 009C 0156 009D 0157 009E 0158 009F 0159
- 00A0 0160 00A1 0161 00A2 0162 00A3 0163
- 00A4 0164 00A5 0165 00A6 0166 00A7 0167
- 00A8 0168 00A9 0169 00AA 0170 00AB 0171
- 00AC 0172 00AD 0173 00AE 0174 00AF 0175
- 00B0 0176 00B1 0177 00B2 0178 00B3 0179
- 00B4 0180 00B5 0181 00B6 0182 00B7 0183
- 00B8 0184 00B9 0185 00BA 0186 00BB 0187
- 00BC 0188 00BD 0189 00BE 0190 00BF 0191
- 00C0 0192 00C1 0193 00C2 0194 00C3 0195
- 00C4 0196 00C5 0197 00C6 0198 00C7 0199
- 00C8 0200 00C9 0201 00CA 0202 00CB 0203
- 00CC 0204 00CD 0205 00CE 0206 00CF 0207
- 00D0 0208 00D1 0209 00D2 0210 00D3 0211
- 00D4 0212 00D5 0213 00D6 0214 00D7 0215
- 00D8 0216 00D9 0217 00DA 0218 00DB 0219
- 00DC 0220 00DD 0221 00DE 0222 00DF 0223
- 00E0 0224 00E1 0225 00E2 0226 00E3 0227
- 00E4 0228 00E5 0229 00E6 0230 00E7 0231
- 00E8 0232 00E9 0233 00EA 0234 00EB 0235
- 00EC 0236 00ED 0237 00EE 0238 00EF 0239
- 00F0 0240 00F1 0241 00F2 0242 00F3 0243
- 00F4 0244 00F5 0245 00F6 0246 00F7 0247
- 00F8 0248 00F9 0249 00FA 0250 00FB 0251
- 00FC 0252 00FD 0253 00FE 0254 00FF 0255
-
- Where HEX = Hexidecimal and DEC = Decimal
-
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 31
-
- CREATING A COMMAND FILE - DETAILS
-
-
-
- To give you an idea of the POWER of SIS LITE, we will now design
- a complex installation. Our goal, to create a multi-level target
- path, from a multi-disk installation set.
-
- For our discussion, we'll call this program (we want to install),
- BIG ACE ! BIG ACE is some high level application which will
- require a hard disk of at least 2 Megabytes, and uses a layered
- directory structure of BASE\SYSTEM , BASE\TOOLS & BASE\CONFIG
-
- The master disk set contains 5 self extracting files, one for
- each of 5 disks. Disk one has 10K available for the install
- program! The 5 self extracting files are identified as :
-
- BIGACE1.EXE --- on disk one
- BIGACE2.EXE --- on disk two
- BIGACE3.EXE --- on disk three
- BIGACE4.EXE --- on disk four
- BIGACE5.EXE --- on disk five
-
- BIGACE1 and BIGACE2 will be loaded into the base directory BASE,
- BIGACE3 will be loaded into BASE\SYSTEM, BIGACE4 into BASE\TOOLS
- and finaly BIGACE5 int BASE\CONFIG .
-
- In this case, BASE will be replaced by a user selected directory.
-
- To begin, start your text editor and select a new file name
- called BIG.SIS . This will be our new command file.
-
- Our first job is to simply display a title screen. Doing, will
- involve a few simple steps. Step one, clear the entire screen to
- default colors.
-
- SETCOLR 7 0
- IFVID SETCOLR 7 1
-
- First set a default color to white on black, to accomidate
- monochrome systems (first line). Next, using the IFVID function,
- check if the system is a color system (2nd line), and if so, set
- the color to white on blue.
-
- Once the colors have been defined as above, we are ready to use
- the CLR function to clear the video area. We know, that the
- system will be set to either 80 column color or 80 column
- monochrome, as SIS performs this initialization task upon entry.
- In fact, that is why the screen blanks momentarily during starup.
-
- {Continued next page}
-
-
-
-
-
- Shareware Installation System Lite PAGE 32
-
- Since we know SIS guarantees us an 80 x 25 screen matrix, we can
- use the following to clear all of the screen to our default
- colors.
-
- CLR 1 1 25 80 @COLR
-
- Notice our use of the COLR variable (prefixed with the @, which
- indicates it's a variable). This variable was set, when we used
- the previous SETCOLR function. In this case, we clear lines 1
- thru 25 (standard video row count) columns 1 thur 80 (standard
- column count) on either a monochrome or color system. The
- difference between clearing occurs from use of the variabe COLR,
- which was previously set depending upon video type.
-
- Now we have the base to draw our opening screen to, so lets make
- it a little snazzy.
-
- SETCOLR 7 0
- IFVID SETCOLR 14 0
- CLR 4 5 8 76 @COLR
-
- Here, we clear a large window, over our base color. First, we set
- the monochrome default value to white on black, and change it to
- yellow on black (2nd line), if the system is color. Finally, we
- clear the window to the selected color. We choose a window of row
- 4 thru 8 and columns 5 thru 76. Our reasons for this size will
- become apparent soon.
-
- We have used the IFVID function now twice, so why not take a
- moment and explain quickly what is happening. During the
- initialization phase, when SIS LITE first starts, an attempt is
- made to put the video system into color mode. On monochrome
- systems, this attempt fails, and SIS LITE will know, and, set a
- flag. This flag, is tested by the IFVID function, and causes a
- postive reation, thus allowing the command following the test, to
- be executed (command on the same line as IFVID, in this case, is
- SETCOLR).
-
- What this does, is establish a shadow effect for our primary
- window, which follows.
-
- SETCOLR 0 7
- IFVID SETCOLR 14 3
- CLR 3 4 7 75 @COLR
-
- This is how we create the fancy shadowed effect, Very Snazzy!
- This set of functions sets monochrome color to black on white,
- and color to yellow on cyan. All that's left, is to draw a
- message into the new box, this is done below.
-
- LOCATE 4 20
- WRITE BIG ACE Action / Adventure System (c) 1992
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 33
-
- We've now gotton or ad onto the screen, which announces what the
- product is. The window could have been made larger to accomidate
- more lines of messages, such as a brief description of the
- product. Just to give an idea, lets throw in a quick description.
-
- LOCATE 6 8
- WRITE A shareware package from Paul Scanlon & Scanlon Enterprises
-
- We now have our little window filled up, so why not make another?
-
- SETCOLR 0 7
- IFVID SETCOLR 15 0
- CLR 12 7 17 77 @COLR
- SETCOLR 0 7
- IFVID SETCOLR 15 4
- CLR 11 6 16 76 @COLR
-
- The above will clear a window as befor on monochrome systems,
- while on color, the new colors are high intense white on red
- (forground color) and intense white on black (shadow).
-
- We are ready to prompt the user for their first input, and thus,
- have become interactive. The following message is placed into our
- newly created window.
-
- LOCATE 12 18
- WRITE Are you ready to install NOW? (Y)es, (N)o < >
-
- Now the prompt is drawn, we need to get the user attention, thus,
- we position the cursor into between the chars "<" and ">", which
- draws the user eye contact.
-
- LOCATE 12 61
-
- This is the only purpose of the above LOCATE function.
-
- We've initialized our prompt, so now, we request SIS LITE to wait
- for a response, in this case, yes or no. The YN function serves
- this purpose.
-
- YN
-
- SIS LITE now wait untill the user presses one of three keys, "Y"
- for yes, "N" for no (these may be upper or lower case), or the
- escape key. Once the user has pressed any one of these keys, the
- next command is executed. In this case, we test the input from
- the YN function for either escape or "N" . The escape is coded as
- an "E" in the YN variable. Since we want to abort if either "N"
- or escape is pressed, we check for each of the negative responses
- and branch if either one is set.
-
- {continued on next page}
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 34
-
- IFYN E GOTO ABORT
- IFYN N GOTO ABORT
-
- First we check for escape "E" and perfor a branch to our abort
- section via a GOTO (branch instruction). Next we test for the "N"
- key which is "no", and again branch via a GOTO to the abort
- section. Any other key, will begin execution of the actual
- installation process.
-
- We have a yes response, so we will reclear the bottom window. The
- lable is only here to clarify that we are starting the
- installation portion of the install routine. In this way, later,
- we can find this spot in the code and make modifications. We
- suggest, however, that these unused labels be removed prior to
- distribution, as they do increase the install program size a tiny
- bit, which in some cases may cause DOS to allocate an extra
- chunck of disk space.
-
- :INSTALL
- CLR 11 6 16 76 @COLR
-
- We've recleared our bottom window, so lets get on with finding a
- target drive. We need to prompt the user for a drive selection,
- so let's do it.
-
- LOCATE 12 18
- WRITE ENTER DESTINATION DRIVE (EXAMPLE: C) >:
-
- Again, we have a prompt, and need to command SIS LITE to get
- keyboard activity, in this case, a drive letter. SIS LITE gets
- the target drive via the GETDRV function.
-
- GETDRV
-
- We could have set a default drive, asked the user it that drive
- was ok, and then prompted for a new drive, but this is easier,
- and only requies a single key press by the user.
-
- In addition to the target drive, we need to ask for a base
- directory. Again, we display a prompt
-
- LOCATE 13 8
- WRITE ENTER THE DESTINATION PATH FOR INSTALLATION (EXAMPLE: \SMS)
-
- We are going to do our input a little differently this time.
- Since our input could be up to 65 characters (a DOS path limit),
- we will clear a little tiny window (most of one line), after
- which we will position our cursor to the start of the new window.
-
- CLR 15 7 15 75 70
- LOCATE 15 7
-
- {continued next page}
-
-
-
-
-
- Shareware Installation System Lite PAGE 35
-
- We now have a window, which is black on white (on monochrome and
- color displays). We now have SIS LITE get the input, we do this
- with the command function LIN.
-
- LIN
-
- The path is now in the line input buffer, so we command SIS LITE
- to transfer the buffer contents to the special variable PTH via
- the SETPTH command.
-
- SETPTH
-
- It is now time we make special mention of a couple of important
- steps SIS LITE has taken at this time and at the time we got a
- target drive.
-
- SIS LITE will provide an errorlevel (reported in the ERR
- variable), of 1 or 2, if the drive selected by the user, does not
- meet the minimum required by you, the developer / author. The
- following commands will provide you with a guideline in using the
- ERR testing method, during the input of target drive and path.
-
- :INSTALL
- CLR 11 6 16 76 @COLR
- LOCATE 12 18
- WRITE ENTER DESTINATION DRIVE (EXAMPLE: C) >:
- GETDRV
- *IFERR 1 GOTO BADRV
- LOCATE 13 8
- WRITE ENTER THE DESTINATION PATH FOR INSTALLATION (EXAMPLE:_
- \BIGACE)
- CLR 15 7 15 75 70
- LOCATE 15 7
- LIN
- SETPTH
- *IFERR 1 GOTO BADPTH
-
- Notice the two lines prefixed with the "*" character. These two
- lines test for error conditions, via the ERR variable. In our
- first test, we wanted to know if the drive was too small or if it
- doesn't exist. Either way, the error level (ERR) will be larger
- than 0, so a branch will be performed, to a label (somewhere
- below the branch instruction) called "BADRV". Hopefully this
- label exists and that we have instructions telling SIS LITE how
- to react to this problem.
-
- Our second use of IFERR is used to let us know that the path
- selected by the user exists already, which could indicate that a
- prior version was already there.
-
- {continued}
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 36
-
- What we have done, now, is provide a base path for the BIGACE
- system. Upon that, we can add our other directories. Let's
- assume, that the above has passed thru, that is, that the target
- drive met our minimum size, and the path does NOT yet exist. In
- that case, we can create the base directory.
-
- MKDIR
-
- This built in function, unlike its namesake, MKDIR, in DOS,
- requires no parameters. This is one of the reasons why SIS LITE
- is so TINY ! In all cases, MKDIR, will create the directory
- specified by the SETPTH function, and which resides in the
- variable, thus created, PTH. In parallel to this, it is also
- REQUIRED, that the target drive has been set. For our example,
- this of course is true.
-
- Upon using the above function, the new directory on the target
- drive will be @PTH, or what ever the user plugs in. For our
- discussion, let's assume, that the user has supplied us with
- drive C, and the base path of BIGACE, our suggested default. Let
- us also assume that the user started from the root, so that the
- new path becomes "C:\BIGACE".
-
- Now that we have a drive and base directory, we can start
- installing files. Our first clump of files belong in the base
- directory "BIGACE", so we need only check that the correct disk
- is inserted into the source drive. SIS LITE has provided for this
- test, with the function IFEXIST, so lets do it.
-
- :TST1
- CLR 11 6 16 76 @COLR
- IFEXIST @SRC:@SPTH\BIGACE1.EXE GOTO CPY1
-
- This command line, will cause SIS LITE to branch to the label
- CPY1 if the source drive and path contain the file BIGACE1.EXE .
- As stated early, in this section, BIGACE1.EXE is one of the two
- files belonging in the base directory. We have now come upon
- another built in feature of SIS LITE. SIS LITE automatically sets
- the two variables, "SRC" and "SPTH" to the correct source drive
- and path. Thus, if the source is drive A (which for our use, we
- will), and the source path is "\" {root} (and we will), then this
- line expects to find "A:\BIGACE1.EXE", and if so, will branch to
- the label "CPY1". We MUST now provide instructions for SIS LITE
- to perform, if the user has inserted a different disk. NOTE, we
- have also precleared our window, to save us from having to
- perform this task twice, once for the case of BIGACE1.EXE
- existing an us branching to label "CPY1", and the other case of
- when the following commands will be executed.
-
-
- {continued next page}
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 37
-
- LOCATE 12 7
- WRITE Please insert BIGACE installation disk #1, into drive @SRC
- LOCATE 13 7
- WRITE If the correct disk is installed, please press ENTER
- LOCATE 14 7
- WRITE if you wish to abort and retry later, press ESCAPE NOW !
- LOCATE 15 7
- WRITE Waiting for your response [ ]
- LOCATE 15 34
- CR
- IFERR 27 GOTO ABORT
- GOTO TST1
-
- Notice the last line, a branch instruction to the above label
- (previous page) TST1, which began the set in commands, prior to
- making the IFEXIST test.
-
- In this code section, we display a nice message, about inserting
- disk one into the source drive. However, this example message
- structure, can be both shortened and lengthed. In the shortening
- approach, we could simply have said, "requires disk #1, press
- ENTER to continue, ESCAPE to abort". The lengthed version might
- go on to provide the user with notes to escape out if this has
- been displayed more than once.
-
- The function CR, simply waits for either an ESCAPE key or ENTER
- key press. All other key presses simply cause the PC speaker to
- beep. Just below the CR function, we test the ERR (errorlevel)
- variable to see if the user pressed the ESCAPE key, and if so,
- branch to the ABORT label, otherwise, the branch instruciton GOTO
- TST1 is performed, and we begin a loop, which is NOT broken,
- until either the correct file is found, or the user aborts by
- pressing the ESCAPE key.
-
- Once the user has the correct disk installed, which we will
- assume is the case, the following instruction is executed.
-
- :CPY1
- BIGACE1.EXE @DRV:@PTH\
-
- In our example, all our installation files are self extracting
- files, similar to the LHA variety, which can extract to a target
- drive and directory.
-
- In the above, all files in the BIGACE1.EXE, self compressed file
- will extract to the target "C:\BIGACE".
-
- This same sequenc can be used for BIGACE2.EXE, like so :
-
-
- {continued next page}
-
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 38
-
- :TST2
- CLR 11 6 16 76 @COLR
- IFEXIST @SRC:@SPTH\BIGACE2.EXE GOTO CPY2
- LOCATE 12 7
- WRITE Please insert BIGACE installation disk #2, into drive @SRC
- LOCATE 13 7
- WRITE If the correct disk is installed, please press ENTER
- LOCATE 14 7
- WRITE if you wish to abort and retry later, press ESCAPE NOW !
- LOCATE 15 7
- WRITE Waiting for your response [ ]
- LOCATE 15 34
- CR
- IFERR 27 GOTO ABORT
- GOTO TST2
- :CPY2
- BIGACE2.EXE @DRV:@PTH\
-
- All we've done, is change the "1's", from our installation of
- BIGACE1.EXE, to a "2" ! Since most text editors now provide a
- block copy function, this code can quickly be created, from the
- first part. Since the above is a clone of the install part one,
- we need not duplicate our explanation, and we move on to
- installation of part 3 (BIGACE3.EXE) which will be in another
- directory off of the base directory of BIGACE !
-
- Our easyest method of installing the last files, will be to first
- logon to the target drive and directory, and begin making the
- required new directories from there.
-
- @DRV:
- CD @PTH
-
- Actually, these two functions are very close to the DOS
- counterparts! The first line, simply sets a new drive via the
- variable DRV, which contains the target drive name. The second
- line performs the change directory function, and changes to the
- target path, contained in the variable PTH. We now use a set of
- two SIS LITE functions, to set a new target path.
-
- We have set the target path to the new path of "SYSTEM", and
- since it's NOT prefixed with the "\" character, SIS LITE will
- create a new path off the current directory, which is BIGACE,
- thus ending up with a true path of "\BIGACE\SYSTEM", which is
- what we want !
-
- We can now tell SIS LITE to make the directory. We need not test
- for the existance of this directory if we don't want to. If the
- directory exists, it exists, we will simply replace any files
- there-in, with new ones.
-
- MKDIR
- CD @PTH
-
-
-
-
-
- Shareware Installation System Lite PAGE 39
-
- We now have made the directory and changed to it. All that left,
- is to verify the correct source disk is inserted and copy files.
- Checking the source disk is just like the previous, so use your
- block copy function to copy the block as follows, changing the
- previous "2's" to a "3".
-
- :TST3
- CLR 11 6 16 76 @COLR
- IFEXIST @SRC:@SPTH\BIGACE3.EXE GOTO CPY3
- LOCATE 12 7
- WRITE Please insert BIGACE installation disk #3, into drive @SRC
- LOCATE 13 7
- WRITE If the correct disk is installed, please press ENTER
- LOCATE 14 7
- WRITE if you wish to abort and retry later, press ESCAPE NOW !
- LOCATE 15 7
- WRITE Waiting for your response [ ]
- LOCATE 15 34
- CR
- IFERR 27 GOTO ABORT
- GOTO TST3
- :CPY3
- BIGACE3.EXE
-
- This time, we don't sufix the selfextracting file with the drive
- and path, as we are there already!
-
- We need only go back one directory level using the CD function
-
- CD ..
-
- and repeat the steps as for installing disk #3, but using the
- path TOOLS for disk #4. Again, we simply block copy the above
- block, edit out the "3's", replacing with "4's".
-
- SETLIN TOOLS
- SETPTH
- MKDIR
- CD @PTH
-
- {continued next page}
-
-
-
-
-
-
- Shareware Installation System Lite PAGE 40
-
- :TST4
- CLR 11 6 16 76 @COLR
- IFEXIST @SRC:@SPTH\BIGACE4.EXE GOTO CPY4
- LOCATE 12 7
- WRITE Please insert BIGACE installation disk #4, into drive @SRC
- LOCATE 13 7
- WRITE If the correct disk is installed, please press ENTER
- LOCATE 14 7
- WRITE if you wish to abort and retry later, press ESCAPE NOW !
- LOCATE 15 7
- WRITE Waiting for your response [ ]
- LOCATE 15 34
- CR
- IFERR 27 GOTO ABORT
- GOTO TST4
- :CPY4
- BIGACE4.EXE
-
- Installing disk #5, is just a repeat of the above, but, we change
- the path name to "CONFIG", the "4's" become "5's"
-
-
- SETLIN TOOLS
- SETPTH
- MKDIR
- CD @PTH
- :TST5
- CLR 11 6 16 76 @COLR
- IFEXIST @SRC:@SPTH\BIGACE5.EXE GOTO CPY5
- LOCATE 12 7
- WRITE Please insert BIGACE installation disk #5, into drive @SRC
- LOCATE 13 7
- WRITE If the correct disk is installed, please press ENTER
- LOCATE 14 7
- WRITE if you wish to abort and retry later, press ESCAPE NOW !
- LOCATE 15 7
- WRITE Waiting for your response [ ]
- LOCATE 15 34
- CR
- IFERR 27 GOTO ABORT
- GOTO TST5
- :CPY5
- BIGACE5.EXE
-
- At this point, BIGACE is installed on the user system (at leaste
- the files are there). For our case, let's suppose that that's
- all there is too it.. Our next step, is to simply announce that
- the system is ready to go, and suggest how to start the program.
-
- First, lets change back to the base directory, which contains the
- start up module for BIGACE.
-
- CD ..
-
-
-
-
-
- Shareware Installation System Lite PAGE 41
-
- Now, clear the entire screen and display a closing message..
-
- CLR
- LOCATE 1 1
- WRITE Installation complete !
- LOCATE 3 1
- WRITE To start BIGACE, TYPE BIGACE
- LOCATE 4 1
- WRITE to read BIGACE documnetation type VIEW BIGACE.DOC
- LOCATE 6 1
-
- Basically, that's all there is to it. We've installed a multi-
- disk, multi-path system ! There are of course, variations on
- this, such as auto-starting the BIGACE program, checking for
- errorlevels after each selfextracting program, etc...
-
- We have provided a fully functional version of the example
- presented in this section, as BIGACE.SIS ! We have NOT provided
- the files BIGACE1.EXE thru BIGACE5.EXE, the selfextracting files.
- You can create these yourself using most compression programs. We
- suggest using LHA due to it's capability. For a copy of the lates
- version of LHA you can send $3 to us, see REG.DOC for address,
- plus postage, or save postage, and get it with your copy of
- registration of SIS LITE, for just $3 ! Postage for us orders is
- $2, all others please include $5.
-