home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1994 #1
/
monster.zip
/
monster
/
UTILS2
/
PATHTL23.ZIP
/
PATHTOOL.DOC
< prev
next >
Wrap
Text File
|
1994-03-03
|
57KB
|
1,441 lines
PathTool
Version 2.3
March 3, 1994
Copyright (C)1990-1994
All Rights Reserved (GTDR)
New World Designs
PO Box 12217
Wichita, KS 67277-2217
U.S.A.
BBS: (316)262-1829, 300-28800 Baud
Internet Email: sysop@nwis.com
The information in this document is subject to change without notice.
PACKING LIST:
If any of the following files are missing, please download
the latest complete version from NWIS BBS (316)262-1829.
4SALE_HW.DOC FILE_ID .DIZ PATHTOOL.EXE WHATSNEW.DOC
4SALE_SW.DOC NWDREG .EXE README .1ST
BUG_RPT .DOC ORDER .DOC SHARE .DOC
DESCRIPT.ION PACKING .LST SUPPORT .DOC
EXAMPLES.ZIP PATHTOOL.DOC VENDOR .DOC
SHAREWARE EVALUATION VERSION WARRANTY:
The shareware version is provided as is. New World Designs makes
NO warranty of any kind, expressed or implied, including without
limitation, any warranties of merchantability and/or fitness for a
particular purpose.
REGISTERED VERSION WARRANTY:
New World Designs warrants the physical diskette provided with
the registered versions to be free of defects in materials and
workmanship for a period of 90 days from the date of registration.
If New World Designs receives notification within the warranty
period of defects in materials or workmanship, and such notification
is determined by New World Designs to be correct, New World Designs
will replace the defective diskette.
The entire and exclusive liability and remedy for breach of this
warranty shall be limited to replacement of defective diskette and
shall not include or extend to any claim for or right to recover any
other damages, including but not limited to, loss of profit, data,
or use of the software, or special, incidental, or consequential
damages or other similar claims, even if New World Designs has
specifically advised of the possibility of such damages. In NO event
will New World Designs liability for any damages to you or any other
person ever exceed the lower of the suggested list price or actual
price paid for the license to use the software, regardless of any
form of the claim!
LICENSE LIMITATIONS:
The licensee shall not use, copy, rent, sell, modify, decompile,
disassemble, reverse engineer, or transfer the licensed program
except as provided in this agreement. Any such unauthorized use
shall result in immediate and automatic termination of this license.
New World Designs grants you the right to use one copy of PathTool
on a single computer. You may not network PathTool or otherwise use
it on more than one computer or computer terminal at the same time.
All rights not specifically granted in this statement are reserved
by New World Designs.
INTRODUCTION:
PathTool is a powerful utility which easily lets users modify the DOS
PATH using straight-forward commands. The worst problem with the PATH
command is changing its contents. Changing the PATH usually requires
the user to retype the entire PATH or to use a text editor to change a
batch file and then execute the batch file. This problem grows even
bigger on systems with many existing installed software packages. This
is especially true of systems connected to a LAN such as Novell Netware.
Many of these systems reach a point where all path entries can't fit in
the PATH because of the 127 character limit of the DOS command line.
The solution until now has been to create many hard to manage batch
files containing the entire PATH. PathTool solves all of these
problems and replaces the Novell MAP command in many situations.
EXPLANATION OF PATH AND ENVIRONMENT STRINGS:
PATH sets a search path for programs and batch files that are not
in the current directory. Once the PATH is defined, programs can run
in other directories without specifying their full pathnames. DOS
searches the current directory then directories in the PATH (in the
specified order and on any drive) until it finds the program or batch
file to be executed. DOS searches the specified path only for files
(those having .COM, .EXE, and .BAT) and then only when attempting to
execute them. The following is the syntax of PATH:
PATH[=][[d:]path1[;[d:]path2...]]
The PATH is stored in the environment string area of the command
processor (COMMAND.COM). All strings defined by SET are also stored
in this area.
INSTRUCTIONS FOR CHANGING THE SIZE OF THE ENVIRONMENT:
The environment size MUST be large enough to hold all environment
strings (including PATH). If it is not, then new strings cannot be
added until the size is expanded. The environment size is set when
your command processor is first executed. Normally, the environment
is 160 bytes by default. A larger size is typically required for most
systems (1024 to 4096). If you experience the PathTool error,
'Environment space full', then the environment size MUST be expanded!
We recommend that you expand your environment before running into that
problem. Normally we run our development machines with 2048 bytes of
environment string space. This will vary depending on your software.
It is not recommended to have a large environment because most of it
will never be used. Also, every time you temporarily "shell" out of a
program to the DOS command prompt, the command processor may allocate
a similar sized environment.
To determine the current size of your environment, the amount of free
space in the environment, and the size of your PATH.
PATHTOOL /YB
To set the size of the environment, change the line in your CONFIG.SYS
as follows for DOS 3.20 and later:
SHELL=C:\COMMAND.COM /E:nnnnn /P
If you would like to experiment with the size of your environment,
type the following example:
COMMAND.COM /E:nnnnn
When finished, type EXIT to return to the original command processor.
Using /E:2048 will create an environment size of 2048 (2K) bytes.
The size can be from 160 to 32768 bytes.
NOTE: DOS 3.10 requires the number of paragraphs instead of the number
of bytes for 'nnnnn'. A paragraph is 16 bytes. Use /E:128 for a 2048
(2K) byte environment. The size can be from 10 to 2048 paragraphs.
NOTE: DOS 3.00 and earlier do NOT support the /E switch. In this case,
you will have to run a patch program for increasing the default size or
change to DOS 3.10 or later. In the first case, see your DOS manual.
NOTE: If you are using 4DOS or other command line replacements, please
read its manual for the proper syntax!
PATHTOOL INNER WORKINGS:
When replacing the PATH, PathTool will first delete the old PATH so
memory will be reused. This will prevent running out of environment
space when it is almost full. Also, the new PATH will be placed at
the beginning of the environment to prevent DOS wasting time searching
for it in a large environment.
UPDATING MULTIPLE ENVIRONMENTS:
Multiple environments may exist in your system simultaneously. This
may occur when using some DOS SHELL programs, loading a secondary
command processor (COMMAND.COM), or "shelling out" of a program.
PathTool defaults to updating the current environment, but the user
has the ability to override this with the /U option. The current
environment is associated with the command processor when PathTool
is run. The option of None is provided for command processors that
are not compatible with COMMAND.COM. A future PathTool release will
allow more control of modifying specific environments.
* EXPLANATION OF DIRECTORY ENTRY:
As described earlier, the PATH string consists of multiple directories
that are searched in order by DOS. This document will refer to the
individual directory as a 'Directory Entry'. Some pathtool commands
will refer to a numbered directory entry using the following convention:
PATH=c:\first;c:\second;c:\third
1 would specify c:\first
2 would specify c:\second
3 would specify c:\third
See the examples in this manual for the proper usage.
USING WITH BATCH FILES:
PathTool can create a batch file containing the new PATH. If you
prefer to run batch files instead of letting PathTool update the
environment, two examples are provided:
Example #1, BAT file:
PATHTOOL %1 %2 %3 %4 %5 %6 %7 %8 %9
IF ERRORLEVEL 1 GOTO ERROR
Example #2, BAT file:
PATHTOOL /WP %1 %2 %3 %4 %5 %6 %7 %8 %9
IF ERRORLEVEL 1 GOTO ERROR
CALL {PATH}.BAT (CALL requires DOS 3.3+)
DEL {PATH}.BAT
:ERROR
USING WITH NOVELL NETWARE:
PathTool can replace the usage of MAP in situations that manipulate
the PATH. Using PathTool will also gain you more flexibility.
NOTE: MAP will not work unless you are logged into the network!
The following three examples describe MAPs' limits:
The following example inserts the directory f:\public\bin at the
first entry in the PATH but not destroying the current first entry:
MAP INSERT SEARCH1: = f:\public\bin
This may be replaced with:
PATHTOOL /I1 f:\public\bin
or
PATHTOOL /F f:\public\bin
The following example inserts the directory f:\public\bin at the
first entry in the PATH:
MAP SEARCH1: = f:\public\bin
This may be replaced with:
PATHTOOL /O1 f:\public\bin
The following example deletes the first entry of the PATH:
MAP DELETE SEARCH1:
or
MAP REMOVE SEARCH1:
This may be replaced with:
PATHTOOL /D1
PathTool cannot replace MAP in the next example since it
creates a search drive by mapping a directory to a drive.
MAP z: = f:\projects\xyz
Thus, use MAP to remap directories and PathTool to manipulate
directories in the PATH.
USING WITH WINDOWS:
If you run a "DOS Box" within Windows, it will receive the same copy
of the environment that Windows did when it started. The DOS Box will
only receive an environment large enough to hold the environment
variables. For example, if you had an extra 300 used bytes in your
environment before booting Windows, you will no longer have them in
your DOS Box. One solution is to add COMMAND.COM /e: parameter to the
optional parameters lines for each of your DOS Box Windows PIF files.
Another solution is to use replace COMMAND.COM with 4DOS. 4DOS will
properly allocate the same environment size in each DOS Box. See the
next section for more information about 4DOS benefits.
The best solution, if you have MSDOS 3.3 or later, is to put the
following lines in the Windows SYSTEM.INI file:
[NonWindowsApp] ;Find this section name within SYSTEM.INI
CommandEnvSize=bytes ;Bytes is 160 to 32767 or 0.
This entry specifies the size of the COMMAND.COM environment. Since
running batch files, with the extension .BAT starts COMMAND.COM, this
setting also applies to batch files. A value of 0 disables this
setting. If the value is less than the current size of the actual
environment, this setting will be disabled, as if it were set to 0.
If you specified the environment size in a PIF for COMMAND.COM, the
PIF setting overrides this setting. The default is 0 with MSDOS
versions earlier than 3.2. Otherwise, the value is the /e: parameter
in the shell= line in the CONFIG.SYS file.
Another problem with Windows is that when you modify the PATH in one
DOS Box, the PATH in other DOS Boxes will not be modified. The reason
behind this problem is each DOS Box doesn't know about the other DOS
Boxes. This is inherent in the original DOS design and not in Windows.
Thus, if you run PathTool from a Windows icon you will only modify the
environment of the DOS Box that is temporarily created to run PathTool.
When PathTool is finished its DOS Box will be destroyed.
To modify the original PATH that is inherited by all DOS Boxes you MUST
exit Windows and run PathTool.
The limitation that is placed on running DOS programs under Windows is
not much of a problem most of the time. We normally run several DOS
Boxes with entirely different PATHs in each DOS Box. For example,
one DOS Box may be modified to run Borland C++ and the other to run
Microsoft C++. Another example could be running two different versions
of Lotus 123 in two DOS Boxes at the same time.
If you would like to modify/set the PATH when starting Windows enhanced
mode, create the batch file WINSTART.BAT in the windows directory and
place a PathTool command line in this file. The PATH you create is only
available to Windows programs and not to the DOS Boxes running inside
of Windows.
If you are running 4DOS and you want to modify/set the PATH each time
you start up a new DOS Box in Windows, reference the 4DOS 4.x section.
Some windows users are using SUBST command to create short "aliases"
for long directory names which allows them to place more directories
in the PATH. It has been stated that "Some windows applications may
act improperly when using SUBST in windows". PathTool can solve this
problem by completely avoiding SUBST and creating PATHs of any length.
USING WITH 4DOS AND NDOS:
The command line replacement, 4DOS & NDOS, can accept 255 characters
on the command line instead of the 127 for COMMAND.COM. To take
advantage of this, add the /L255 or /L0 option to PATHTOOL. However,
you may not want to take advantage of 4DOS or NDOS if you plan to use
the batch file on computers which have COMMAND.COM.
USING WITH 4DOS/NDOS v4 or v5:
If you are using 4DOS, we highly recommend you add the following
lines (or something similar) into your 4DOS.INI file:
Environment = 1024 ;Sets the amount of memory allocated to the
;environment in bytes. The allowable range of
;values is 256 to 32000 bytes. Default is 512.
EnvFree = 256 ;Sets the minimum amount of memory in bytes that
;will be available in the environment for secondary
;shells. 4DOS will enlarge the environment for
;each secondary shell, if necessary, so that there
;is at least this much free environment space when
;the shell starts. The allowable range of values
;is 128 to 32000 bytes. Default is 128.
If you want to modify/set the PATH each time you start up a new DOS Box
in Windows, you should read the following excerpt from the 4DOS manual.
4DOS allows you to place a command to be executed as the last
parameter on your 4DOS command line. This command is executed
before 4DOS displays its first prompt. You can use this
feature to run a batch file (or any other command) each time a
4DOS window is started by your multitasker. For example, if
you are setting up 4DOS to run as a DOS application under
Windows 3.0, your command line might look this:
c:\4dos\4dos.com //swapping=f:\ c:\winstart.btm
This tells Windows to load 4DOS, includes a 4DOS.INI directive
to tell 4DOS to swap to drive F, and passes 4DOS the command
C:\WINSTART.BTM. You can place commands in C:\WINSTART.BTM to
be executed whenever such a window is started (for example, to
change your PROMPT to show that you're in a window, or to load
a TSR for just that window). The command to be executed
(C:\WINSTART.BTM in this example), must be the last thing on
the 4DOS command line; no 4DOS switches or options can be
placed after it because anything after the command will be
interpreted as parameters for the command.
This command feature is similar to what's provided by the
4START batch file, but 4START is executed every time 4DOS
loads, whereas a file like WINSTART will be executed only when
a 4DOS window is started from your multitasker. A batch file
started this way will be run after 4START.
USING WITH OTHER COMMAND.COM REPLACEMENTS:
Some COMMAND.COM replacements, which are not compatible with the
PSP and environment strings, may require PATHTOOL to create a
batch file containing the new PATH. COMMAND.COM and 4DOS do not
require this procedure.
Example #1, BAT file:
PATHTOOL /UN /WP [other switches...]
CALL {PATH}.BAT
Example #2, TYPE ON COMMAND LINE:
PATHTOOL /UN /WP [other switches...]
{PATH}.BAT
If you are a manufacturer of any command line replacement software,
please contact us so we can put a section in our manual about it!
USEFUL TIPS:
This program was designed to give you the most use from the command
line. Type PATHTOOL without any parameters. A numbered list of
directory entries along with a list of all commands and options
will be displayed to help you type the next command line.
You don't even need to remember any commands or options when running
PathTool in the future. If you give a directory argument by itself,
PathTool will automatically use the /E command as default and append
the directory to the end of the current PATH.
i.e. PATHTOOL c:\new_util SAME AS PATHTOOL /E c:\new_util
ENVIRONMENT VARIABLE:
Default PathTool options can be put in the "PATHTOOL=" environment
string. Only options are allowed. For example:
SET PATHTOOL=/YB /L127
To disable these options at a later time, use the /NA option.
SUMMARY:
PATHTOOL [{/-}command] [{/-}options...] [directories...]
COMMANDS:
Ad : Insert directory(s) After matching directory `d' in PATH.
Bd : Insert directory(s) Before matching directory `d' in PATH.
C : Compare directory(s) with PATH and set ERRORLEVEL.
D : Delete directory(s) from PATH.
Dm : Delete `m' entry from PATH.
Dm-n : Delete `m' thru `n' entry from PATH.
Dm- : Delete `m' thru last entry from PATH.
E : Add directory(s) to End of PATH.
F : Add directory(s) to Front of PATH.
Im : Insert directory(s) starting at `m' entry in PATH.
Om : Overwrite `m' entry with directory(s).
Sm=n : Swap directories positioned at `m' and `n' entry in PATH.
ZEFn : If Environment Free less than 'n', set ERRORLEVEL to 1.
ZESn : If Environment Size less than 'n', set ERRORLEVEL to 1.
ZEUn : If Environment Used less than 'n', set ERRORLEVEL to 1.
ZVLn : If PATH or /Ge Var Len less than 'n', set ERRORLEVEL to 1.
H : Display short help text.
? : Display long help text.
$ : Display license information text.
OPTIONS:
Ln : Maximum Length of PATH `n' (in bytes) including 'PATH='.
Set `n' to 127 for portability. Set `n' to 0 to use all
environment free space. The SHAREWARE version defaults to 127
for DOS and 255 for 4DOS. REGISTERED version defaults to 0.
Ge : Get path from environment string `e' before processing it.
Ke : Put path into environment string `e' after processing it.
Pe : Put path into environment string `e' before processing it.
Default environment string is OLDPATH.
NA : Suppress options from PATHTOOL environment string.
NB : Suppress displaying size of new path and environment. Default.
ND : Suppress error on deleting directory not in PATH. Default.
NE : Suppress displaying ERRORLEVEL return code. Default.
NF : Suppress converting directories to full path name.
NI : Suppress error on inserting directory already in PATH. Default.
NM : Suppress moving directory if it already exists in PATH.
NP : Suppress displaying new PATH.
NS : Suppress displaying separate directories of new PATH. Default.
NT : Suppress displaying title banner.
NVC : Suppress verify existence of directories on command line.
NVE : Suppress verify existence of directories in PATH.
NVR : Suppress verify redundant directories in PATH.
NW : Suppress warning messages.
RD=f : Read file `f' with Directories. Default is {DIR}.TXT.
WD=f : Write file `f' with Directories. Default is {DIR}.TXT.
RP=f : Read file `f' with full PATH. Default is {PATH}.BAT.
WP=f : Write file `f' with full PATH. Default is {PATH}.BAT.
Uc : Update specified environments. Default `c' is C.
Set `c' to C=current or N=none.
YA : Allow options from PATHTOOL environment string. Default.
YB : Display size of new path, environment size and free.
YD : Allow error on deleting directory not in PATH.
YE : Display ERRORLEVEL return code.
YF : Converting directories to full path name. Default.
YI : Allow error on inserting directory already in PATH.
YM : Allow moving directory if it already exists in PATH. Default.
YP : Display new PATH. Default.
YSn : Display separate directories of new PATH.
`n'=0 to 3. Default `n' is 0.
YT : Display title banner. Default.
YVC : Verify existence of directories on command line. Default.
YVE : Verify existence of directories in PATH. Default.
YVR : Verify redundant directories in PATH. Default.
YW : Display warning messages. Default.
COMMAND DESCRIPTIONS:
- ONLY one command can be used on the command line.
- The order of commands and options is not critical.
- All commands must be preceded with either / or -.
- Commands with sub-parameters must connect without spaces.
- Commands can't be put in the environment string "PATHTOOL=".
Ad : Insert directory(s) After matching directory `d' in PATH.
If the directory 'd' is in the PATH, then directories, from the
command line, will be inserted into the PATH after the matching
directory 'd'. All inserted directories must exist on valid
drives or else none of the directories will be inserted.
Also see /NI and /YI options for error control!
Bd : Insert directory(s) Before matching directory `d' in PATH.
If the directory 'd' is in the PATH, then directories, from the
command line, will be inserted into the PATH before the matching
directory 'd'. All inserted directories must exist on valid
drives or else none of the directories will be inserted.
Also see /NI and /YI options for error control!
C : Compare directory(s) with PATH and set the ERRORLEVEL. If all
the directories are found then 0 is returned, otherwise 2 is
returned in the ERRORLEVEL.
i.e. PATH=c:\;c:\dos;d:\
PATHTOOL /C c:\dos
ERRORLEVEL is 0
i.e. PATH=c:\;c:\dos
PATHTOOL /C c:\windows
ERRORLEVEL is 2
D : Delete directory(s) from PATH. If all of the directory(s) on
the command line are in the PATH, then they will be deleted.
Also see /ND and /YD options for error control!
Dm : Delete `m' entry from PATH.
Dm-n : Delete `m' thru `n' entry from PATH.
Dm- : Delete `m' thru last entry from PATH.
If the directory entry(s) exist, then they will be deleted.
See the text describing directory entries.
E : Add directory(s) to End of PATH.
All specified directories to be added must exist on valid drives
or else none of the directories will be added. Also see /NI and
/YI options for error control!
F : Add directory(s) to Front of PATH.
All specified directories to be added must exist on valid drives
or else none of the directories will be added. Also see /NI and
/YI options for error control!
Im : Insert directory(s) starting at `m' entry in PATH.
All specified directories to be inserted must exist on valid
drives or else none of the directories will be inserted. See
the text describing directory entries. See /NI and /YI options
for error control!
Om : Overwrite starting at `m' entry with directory(s).
All specified directories to be overwritten must exist on valid
drives or else none of the directories will be overwritten.
See the text describing directory entries.
Sm=n : Swap directories positioned at `m' and `n' entry in PATH.
If both directory entries exist, then the directories will
be swapped. See the text describing directory entries.
ZEFn : If Environment Free is less than 'n', set ERRORLEVEL to 1.
Otherwise it will return 0. Great to determine if you have
enough free environment space before setting variables.
ZESn : If Environment Size is less than 'n', set ERRORLEVEL to 1.
Otherwise it will return 0.
ZEUn : If Environment Used is less than 'n', set ERRORLEVEL to 1.
Otherwise it will return 0.
ZVLn : If PATH or /Ge Var Len less than 'n', set ERRORLEVEL to 1.
Otherwise it will return 0.
H : Display short help text.
? : Display long help text.
$ : Display license information text.
OPTION DESCRIPTIONS:
- The order of commands and options are not critical.
- All options must be preceded with either / or -.
- Options with sub-parameters must connect without spaces.
- Set the environment string "PATHTOOL=" with default options.
Ln : Maximum Length of PATH `n' (in bytes) including 'PATH='.
NOTE: The REGISTERED version defaults to 0 which allows access
to the entire environment free space. The SHAREWARE version
defaults to 255 and is limited to 255. Command.com can accept
127 characters on the DOS command line. 4DOS can accept 255
characters on the DOS command line. If you use PathTool, the
only limit is the environment size.
Ge : Get path from environment string `e' before processing it.
If an environment string is not specified, then the default
'OLDPATH=' will be used. This option provides a quick method
to set the PATH by recalling previously stored PATH. Use the
/K option to modify an environment variable other than PATH.
For example you can modify LIB and INCLUDE for your compiler.
See the /K and /P options.
Ke : Put path into environment string `e' after processing it,
instead of PATH. The 'e' is optional if it is already given
with the /Ge option or if the /RP file contains a variable name.
This option is perfect for modifying variables that have a
similar format as "PATH". Any one using Microsoft Compilers or
LINT will love this feature to modify LIB & INCLUDE variables.
i.e. PATHTOOL /GLIB /K /F c:\msvc10\lib
Pe : Put path in environment string `e' before processing it.
If an environment string is not specified, then the default
'OLDPATH=' will be used. This option provides a quick method
to save the PATH for future recall by the /G option.
NA : Suppress options contained in PATHTOOL environment string.
Opposite of /YA option.
i.e. set PATHTOOL=/NVC /NVE /NVR
PATHTOOL /NA /E c:\tmp
NB : Suppress displaying size of new path and environment.
Opposite of /YB option.
ND : Suppress error on deleting directory not in PATH. Default.
Opposite of /YD option.
NE : Suppress displaying ERRORLEVEL return code. Default.
Opposite of /YE option.
NF : Suppress converting directories to full path name. This is
recommended when trying to insert the following directories
into PATH: F:. OR . OR ..\tools Opposite of /YF option.
NI : Suppress error on inserting directory already in PATH. Default.
Opposite of /YI option.
NM : Suppress moving directory if it already exists in PATH. Use this
to be compatible with version 2.1. Opposite of /YM option.
NP : Suppress displaying new PATH. This is provided for usage in
batch file situations to keep PathTool "quiet".
Opposite of /YP option.
NS : Suppress displaying separate directories of new PATH.
Same as /YS0 option.
NT : Suppress displaying title banner. This is provided for usage
in batch file situations to keep PathTool "quiet".
Opposite of /YT option.
NVC : Suppress verify existence of directories on command line.
Opposite of /YVC option.
NVE : Suppress verify existence of directories in PATH.
Opposite of /YVE option.
NVR : Suppress verify redundant directories in PATH.
Opposite of /YVR option.
NW : Suppress warning messages. Opposite of /YW option.
RD=f : Read file `f' with Directories. This option will read a file
written by the /WD option. Default file name is {DIR}.TXT.
WD=f : Write file `f' for Directories. Make a file containing
individual directories on separate lines. Similar to /YS1.
The default file name is '{DIR}.TXT'.
RP=f : Read file `f' with full PATH. This option will read a file
written by the /WP option. Default file name is {PATH}.BAT
WP=f : Write file `f' with full PATH. Make a batch file containing
the new PATH. The default file name is '{PATH}.BAT'.
Refer to 'USING WITH OTHER COMMAND.COM REPLACEMENTS'.
Uc : Update specified environments. The default 'c' is C.
C : Update Current environment.
N : Update NO environments.
YA : Allow options from PATHTOOL environment string. Default.
Opposite of /NA option.
YB : Display size of new path, environment size, and environment
free size. All numbers are specified in bytes. This option
is very useful to help solve "Environment space full" problems.
If the environment free is TOO small, errors may occur in the
future. Refer to the discussion about the environment to
increase the environment size. Opposite of /NB option.
YD : Allow error on deleting directory not in PATH. If any directory
does NOT exist when using the /D command an error will occur and
PathTool will abort. This was the default on PathTool v1.0.
Opposite of /ND option.
YE : Display ERRORLEVEL return code. This option is provided to
help debug problems in batch files. Opposite of /NE option.
YF : Convert directories to full path name. Default. Directories
will be converted to the full path name. For example, c:. might
be converted to c:\dos before being placed into the PATH. If you
don't wish the directories to be converted use the /NF option.
YI : Allow error on inserting directory already in PATH. If any
directory exists when using the /A, /B, /E, /F, or /I command
an error will occur and PathTool will abort. This was the
default on PathTool v1.0. Opposite of /NI option.
YM : Allow moving directory if it already exists in PATH. Default.
Opposite of /ND option.
i.e. PATH=c:\;d:\;c:\dos
PATHTOOL /F c:\dos
YP : Display new PATH. Default. Opposite of /NP option.
YSn : Display separate directories of new PATH. Default 'n' is 0.
0 : Don't display separate directories.
1 : Show directories on individual lines.
2 : Same as 1 with leading numbered lines.
3 : Show directories in numbered two column format.
YT : Display title banner. Default. Opposite of /NT option.
YVC : Verify existence of directories on command line. Default!
Checks if directories exist.
YVE : Verify existence of directories in PATH. Default!
Useful after login off a network to clean up directories.
Also useful to remove old directories no longer on drive.
YVR : Verify redundant directories in PATH. Default!
Useful to clean up multiple copies of the same directory.
DOS wastes time searching through the same directory twice!
YW : Display warning messages. Default. Opposite of /NW option.
DIRECTORY DESCRIPTIONS: (LAST PATHTOOL PARAMETER)
Multiple directories must be specified in the correct order for proper
placement. Only the REGISTERED version supports multiple directories.
Directories can either be given in a full path format consisting
of the drive and directory or a partial directory path.
FULL PATH EXAMPLE:
c:\tools\arctools
PARTIAL PATH EXAMPLES: (Also see /NF and /YF options).
.
..\arctools
\tools\arctools
NOTE: Partial paths only work on directories that are NOT part
of a command. Example: /A. and /B\TOOLS are WRONG!
ERRORLEVEL SUMMARY:
0 = OK or directory found.
1 = Directory is already in PATH.
2 = Directory is not in PATH.
3 = Directory does not exist on drive.
4 = Directory entry# out of range.
10 = New PATH length is too long.
20 = Can't create file.
25 = Can't read file.
26 = Can't read file because bad format.
30 = Environment space full.
70 = Command or option error.
71 = Command in PATHTOOL environment string.
72 = Directory in PATHTOOL environment string.
SOLUTIONS TO COMMON PATHTOOL ERRORS:
1: A command contains a directory which already is in the PATH.
2: A command contains a directory which is not in the PATH.
Also used for /C command but is not an error in that case.
3: A directory has been specified which does not exist.
New directories are validated before adding to the PATH.
4: A directory entry number is bad. It is either negative,
does not exist, or contains a non-numeric character.
10: The new PATH is too long. Use /L to change the maximum length.
NOTE: The /L option cannot be longer than 255 on the shareware
version. The registered version is only limited to the size
of the environment.
20: DOS error when creating a file for /WD or /WP option.
25: DOS error when reading a file for /RD or /RP option.
26: File specified by /RD or /RP is in wrong format.
Must be in a format similar to file created by /WD or /WP.
30: Enlarge environment space. See discussion about enlarging the
environment space for the command processor.
70: Check syntax and examples for improper usage.
71: Remove command from the PATHTOOL environment string.
72: Remove directory from the PATHTOOL environment string.
EXAMPLE SUMMARY: (See limitations of non-registered version)
PATHTOOL /$
PATHTOOL /?
PATHTOOL /Ac:\match c:\onlydir
PATHTOOL /Ac:\match c:\first c:\last
PATHTOOL /Bc:\match c:\onlydir
PATHTOOL /Bc:\match c:\first c:\last /L127
PATHTOOL /D c:\onlydir
PATHTOOL /D c:\first c:\last
PATHTOOL /D3
PATHTOOL /D3-4
PATHTOOL /D3-
PATHTOOL /E c:\onlydir
PATHTOOL /E c:\first c:\last
PATHTOOL /F c:\onlydir
PATHTOOL /F c:\first c:\last
PATHTOOL /H
PATHTOOL /I4 c:\onlydir
PATHTOOL /I4 c:\first c:\last
PATHTOOL /O2 c:\onlydir
PATHTOOL /O2 c:\first c:\last
PATHTOOL /S2=4
PATHTOOL /NT /NP [other switches...]
PATHTOOL >dirs.txt /YS1 /NT /NP /WP
PATHTOOL /WD /WP
PATHTOOL /UN /WP [other switches...]
PATHTOOL /YB /R [other switches...]
PATHTOOL /G [other switches...]
PATHTOOL /GOLD1 [other switches...]
PATHTOOL /P [other switches...]
PATHTOOL /F .
EXAMPLES: (See limitations of non-registered version)
1) Display quick help text and columnized path.
Example: PATHTOOL
2) Display short help text and normal path.
Example: PATHTOOL /H
3) Display long help text and no path.
Example: PATHTOOL /?
4) Display license text.
Example: PATHTOOL /$
5) If c:\match exists in PATH then insert c:\onlydir after it.
Example: PATHTOOL /Ac:\match c:\onlydir
Old: PATH=c:\;c:\match;d:\
New: PATH=c:\;c:\match;c:\onlydir;d:\
6) If c:\match exists in PATH then insert c:\first & c:\last after it.
Example: PATHTOOL /Ac:\match c:\first c:\last
Old: PATH=c:\;c:\match;d:\
New: PATH=c:\;c:\match;c:\first;c:\last;d:\
7) If c:\match exists in PATH then insert c:\onlydir before it.
Example: PATHTOOL /Bc:\match c:\onlydir
Old: PATH=c:\;c:\match;d:\
New: PATH=c:\;c:\onlydir;c:\match;d:\
8) If c:\match exists in PATH then insert c:\first & c:\last before it.
Example: PATHTOOL /Bc:\match c:\first c:\last
Old: PATH=c:\;c:\match;d:\
New: PATH=c:\;c:\first;c:\last;c:\match;d:\
9) If c:\onlydir exists in PATH then delete it from PATH.
Example: PATHTOOL /D c:\onlydir
Old: PATH=c:\;c:\onlydir;d:\
New: PATH=c:\;d:\
10) If c:\first & c:\last exists in PATH then delete them from PATH.
Example: PATHTOOL /D c:\first c:\last
Old: PATH=c:\last;c:\;c:\first;d:\
New: PATH=c:\;d:\
11) Delete the 3rd path entry from PATH.
Example: PATHTOOL /D3
Old: PATH=c:\;d:\;e:\;f:\;g:\;h:\
New: PATH=c:\;d:\;f:\;g:\;h:\
12) Delete the 3rd thru 5th path entry from PATH.
Example: PATHTOOL /D3-5
Old: PATH=c:\;d:\;e:\;f:\;g:\;h:\
New: PATH=c:\;d:\;h:\
13) Delete the 3rd thru last path entry from PATH.
Example: PATHTOOL /D3-
Old: PATH=c:\;d:\;e:\;f:\;g:\;h:\
New: PATH=c:\;d:\
14) Add c:\onlydir to end of PATH.
Example: PATHTOOL /E c:\onlydir
Old: PATH=c:\;d:\
New: PATH=c:\;d:\;c:\onlydir
15) Add c:\first & c:\last to end of PATH.
Example: PATHTOOL /E c:\first c:\last
Old: PATH=c:\;d:\
New: PATH=c:\;d:\;c:\first;c:\last
16) Add c:\onlydir to front of PATH.
Example: PATHTOOL /F c:\onlydir
Old: PATH=c:\;d:\
New: PATH=c:\onlydir;c:\;d:\
17) Add c:\first & c:\last to front of PATH.
Example: PATHTOOL /F c:\first c:\last
Old: PATH=c:\;d:\
New: PATH=c:\first;c:\last;c:\;d:\
18) Insert c:\onlydir at the 4th path entry.
Example: PATHTOOL /I4 c:\onlydir
Old: PATH=c:\;d:\;e:\;f:\;g:\
New: PATH=c:\;d:\;e:\;c:\onlydir;f:\;g:\
19) Insert c:\first & c:\last starting at the 4th path entry.
Example: PATHTOOL /I4 c:\first c:\last
Old: PATH=c:\;d:\;e:\;f:\;g:\
New: PATH=c:\;d:\;e:\;c:\first;c:\last;f:\;g:\
20) Overwrite the 2nd path entry with c:\onlydir.
Example: PATHTOOL /O2 c:\onlydir
Old: PATH=c:\;d:\;e:\
New: PATH=c:\;c:\onlydir;e:\
21) Overwrite the 2nd & 3rd path entry with c:\first & c:\last.
Example: PATHTOOL /O2 c:\first c:\last
Old: PATH=c:\;d:\;e:\
New: PATH=c:\;c:\first;c:\last
22) Swap the 2nd & 4th path entries.
Example: PATHTOOL /S2=4
Old: PATH=c:\;d:\;e:\;f:\;g:\
New: PATH=c:\;f:\;e:\;d:\;g:\
23) Do not display the PathTool banner or PATH.
Example: PATHTOOL /NT /NP [other switches...]
24) Create a text file containing each path entry on separate lines
and a legal batch file that contains 'PATH=...'
Example: PATHTOOL >dirs.txt /YS1 /NT /NP /WP
25) Create a text file containing each path entry on separate lines
and a legal batch file that contains 'PATH=...'
Example: PATHTOOL /WD /WP
26) Create a legal batch file containing PATH= and do not update
the environment with the new PATH. This is for COMMAND.COM
replacements which are not 100% compatible.
Example: PATHTOOL /UN /WP [other switches...]
27) Show size of path, environment size, and environment free bytes.
Also show ERRORLEVEL returned to DOS.
Example: PATHTOOL /YB /R [other switches...]
28) Get path from default environment string 'OLDPATH'
before processing it.
Example: PATHTOOL /G [other switches...]
29) Get path from environment string 'OLD1' before processing it.
Example: PATHTOOL /GOLD1 [other switches...]
30) Put path into default environment string 'OLDPATH'
before processing it.
Example: PATHTOOL /P [other switches...]
31) Add current directory to front of PATH.
Directories do not have to be a full path.
Example: PATHTOOL /F .
SYSTEM REQUIREMENTS:
o DOS 2.1 or later. Best with DOS 3.1 or later.
Has been tested with MSDOS 3.3, MSDOS 5.0, MSDOS 6.0,
Windows DOS Box, OS/2 DOS Box, Novell Netware v3.11.
o 64K RAM available to application (after DOS loaded).
SUPPORT:
o Call: New World Information Service (NWIS) BBS, (316)262-1829
300-28800 baud modem, 24hrs, .QWK packet mail door.
Over 3 years online with more than 70000 calls.
o Internet Email: sysop@nwis.com
o Write: New World Designs
PO Box 12217
Wichita, KS 67277-2217
>>> REGISTERED VERSION ADDITIONS:
o Create PATHs longer than 255 bytes with the /L option.
o Commands handle multiple directories. Only the first directory
is processed on the shareware version.
o If you order a floppy disk, additional shareware from our BBS
will fill up the remaining unused space.
CUSTOM FEATURES:
o Customization is available but isn't included with the
registration fee. Contact us for a quote!
o If a feature can be included in a normal PathTool release,
the cost might be waived.
o You must register PathTool before any customization!
FUTURE ADDITIONS:
o We have many NEW commands and options on our wish list.
Look for NEW versions coming in the near future!
ACKNOWLEDGEMENTS:
Programmer - Steve Meirowsky.
Proofreader - Laura Haas.
Beta Tester - Ron Flory, David Hagood, Jeff Rayner.
TRADEMARK ACKNOWLEDGEMENTS:
4DOS is a registered trademark of J.P. Software.
IBM is a trademark of International Business Machines Corporation.
MSDOS is a registered trademark of Microsoft Corporation.
NDOS is a registered trademark of Symantec.
NetWare & Novell are registered trademarks of Novell, Inc.
PathTool rights and usage are reserved by New World Designs.
DISK VENDOR INFORMATION:
Shareware distributors and disk vendors who wish to distribute
the PATHTOOL package MUST comply with the following restrictions:
o You may NOT list any of our products in advertisements, catalogs,
or other literature which describes our products as "FREE SOFTWARE".
It must be stated that this software is shareware and the term
shareware must be explained so that users know the software is
copyrighted and that an additional fee must be paid if they use it.
o You can't modify any of the files supplied by us. All the files
must be distributed together, although other files may be added.
o You must stop selling copies of our software upon written notice.
o We would appreciate that ALL vendors notify us if any of our
products are listed in your catalogs or distributed as part of
a collection including CD-ROMS. If you comply, we will send you
the next software release.
o We would appreciate you check our BBS for the most recent version
before distributing. Please leave us a message when calling!
REVISION HISTORY:
Version 2.3 (Mar-3-1994)
o Add /ZEFn, /ZESn, /ZEUn, /ZVLn commands to return comparison
in the ERRORLEVEL. Requested by STEVE MEIROWSKY.
o Add /YW and /NW options to enable/disable display of warnings
during verification of directory existence.
Requested by JAY JURCZYNSKI!
o Increased maximum number of directories in PATH to 128.
Can handle the following MSDOS 6.2 example:
dir /ad /b /f c:\*.* >{dir}.txt
pathtool /rd
o Fixed /RD to report not having enough directory entries.
Reported by IVAN COWIE!
o Fixed WARNING for Non-existent dir from /YVD to /YVE. Typo...
Reported by JAY JURCZYNSKI!
o Fixed problem caused by strtok() destroying original date string.
Didn't cause any PATHTOOL functional problems.
Version 2.2 (Aug-3-1993)
o Overview
- Added 1 new command.
- Added 7 new options.
o Added /C command to compare directories with PATH and set the
ERRORLEVEL. If ALL directories are found then 0 is returned,
otherwise 2 is returned in ERRORLEVEL.
i.e. PATH=c:\;c:\dos;d:\
PATHTOOL /C c:\dos
ERRORLEVEL is 0
i.e. PATH=c:\;c:\dos
PATHTOOL /C c:\windows
ERRORLEVEL is 2
o Added /Ke option to put the path into an environment variable `e'
after processing it, instead of PATH. The 'e' is optional if it
is already given with the /Ge option or if the /RP file contains
a variable name. This option is perfect for modifying variables
that have a similar format as "PATH". Any one using Microsoft
Compilers or LINT will love this feature to modify LIB, INCLUDE,
and HELPFILES variables.
i.e. PATHTOOL /GLIB /K /F c:\msvc10\lib
o Added /RD=f option to read a file 'f' with directories. This will
read a file written by the /WD option format. Default is {DIR}.TXT.
i.e. PATHTOOL /RD
o Added /RP=f option to read a file 'f' with a full path. This will
read a file written by the /WP option format. Default is {PATH}.BAT.
i.e. PATHTOOL /RP
o Added /YM option to allow moving a directory if it already exists
in the PATH. The /YM option is the default. Use /NM to make it
compatibile with PathTool v2.1 which didn't move the directory.
i.e. PATH=c:\;d:\;c:\dos
PATHTOOL /F c:\dos
o Added /NA & /YA options. The /NA option suppresses all options
from the "PATHTOOL" environment string. The /YA option is default.
i.e. set PATHTOOL=/NVC /NVE /NVR
PATHTOOL /NA /E c:\tmp
o Added default command of /E when a directory is given without a
command! It use to give an error on PathTool v2.1.
i.e. PATHTOOL c:\ same as PATHTOOL /E c:\
o Added showing of detected DOS and 4DOS versions after title banner.
Use /NT to remove the title banner and this new information.
o Added errors 25 and 26.
o Added serial# & registration line to /?, /H, /$.
o Changed "PATH" variable to always be forced to upper case in all
situations. The /K option will override this feature when writing
to a variable other than "PATH". Fixed situation where "PATH" was
lower case before running PATHTOOL.
o Changed /G option. If the environment variable doesn't exist,
then PathTool won't get it from the "PATH" variable. Instead,
the starting variable that PathTool uses will be empty.
o Modified error 70 to state argument number that caused error.
o Fixed /L defaults for non-registered users to: 127 for MSDOS and
255 for 4DOS/NDOS. This is mainly for compatibility sake.
o Fixed /YVR bug when there weren't at least 2 directories in final
PATH" environment string.
o Fixed /YVC & /YVE when initial "PATH" environment string drive
letters were lower case.
Version 2.1 (Feb-07-1993)
o Change maximum PATH length for SHAREWARE version to 255 since
4DOS allows 255 characters on the command line. See /L option.
o Rename /MD option to /WD=f. Rename /MP option to /WP=f.
o Deleted documented references of /MD and /MP options.
Even though still supported, these options may not exist in
future versions of PathTool.
o Add /YVR and /NVR options to enable/disable verify redundant
directories in PATH. Default is /YVR.
o Add /YVE and /NVE options to enable/disable verify existence
of directories in PATH. Default is /YVE.
o Deleted documented references of /NV, /YV0, and /YV1 options.
Even though still supported, these options may not exist in
future versions of PathTool.
o Rename /YV1 option to /YVC. Rename /NV & /YV0 option to /NVC.
Default is /YVC.
o Add additional drive directory checking in /YVC option.
o Add descript.ion file for 4DOS/NDOS users.
o Add readme.1st, packing.lst, vendor.doc files.
o Change order form.
o Change rights for shareware distribution vendors.
Version 2.0 (May-11-1992)
o Add "PATHTOOL=" environment string for default options.
o Add /YF and /NF options. For directory conversion to full
path. The default is /YF. If you want to add a directory of
`F:.' or `.' then you must use the /NF option.
o Add /ND and /YD options. For control of errors when deleting
directories. With /YD option, deleting a directory which does
NOT exist in the PATH will cause an error. /ND is default!
o Add /NI and /YI options. For control of errors when inserting
directories. With /YI option, inserting a directory which does
exist in the PATH will cause an error. Commands A,B,E,F,I are
considered insert type commands. /NI is default!
o Add /YVn and /NV options. For verifing directories. /NV and
/YV0 means don't do any verification. /YV1 means to verify the
directories on the command line.
o Add /NB, /NE, /NS, /YT, /YP options. Complement of other options.
All of these options are defaults. They are meant for overriding
purposes from the command line in-case their complements were
used in the "PATHTOOL=" environment string.
o Fix /WP option by adding missing CR/LF.
o Fix /L so will accept up to 9999. It was 999. Zero is unlimited.
o Enhance verification of all directories on the command line.
Also checks if drive exists.
o Change error format to 'ERROR PTxxx'. It was 'ERRORxxx'.
o No longer shows path directories on errors.
o Change help descriptions.
Version 1.0 (Sep-02-1991)
o First shareware release.