0% found this document useful (0 votes)
19 views2 pages

WIN95CLT

This document is a batch script for updating client files in a specified profile directory. It checks for the existence of necessary files and directories, handles errors, and provides usage instructions if the required parameters are not supplied. The script also includes conditions for managing multiple subdirectories and copying specific files from a source to a target location.

Uploaded by

nn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views2 pages

WIN95CLT

This document is a batch script for updating client files in a specified profile directory. It checks for the existence of necessary files and directories, handles errors, and provides usage instructions if the required parameters are not supplied. The script also includes conditions for managing multiple subdirectories and copying specific files from a source to a target location.

Uploaded by

nn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

@echo OFF

if "%1"=="" goto USAGE


if "%2"=="" goto USAGE
if "%3"=="" goto USAGE
set SUBOOTDIR=
if exist %1\suboot\system.dat set SUBOOTDIR=suboot
if exist %1\suboot.000\system.dat set SUBOOTDIR=suboot.000
if exist %1\suboot.001\system.dat set SUBOOTDIR=suboot.001
if exist %1\suboot.002\system.dat set SUBOOTDIR=suboot.002
if exist %1\suboot.003\system.dat set SUBOOTDIR=suboot.003
if exist %1\suboot.004\system.dat set SUBOOTDIR=suboot.004
if exist %1\suboot.005\system.dat set SUBOOTDIR=suboot.005
if exist %1\suboot.006\system.dat set SUBOOTDIR=suboot.006
if exist %1\suboot.007\system.dat set SUBOOTDIR=suboot.007
if exist %1\suboot.008\system.dat set SUBOOTDIR=suboot.008
if exist %1\suboot.009\system.dat goto TOOMANYSUBOOT
if "%SUBOOTDIR%"=="" goto NOSYSTEMDAT
if not exist %2\rplfiles\profiles\%3\LANMAN.DOS\LANMAN.INI goto NODATA
if exist %2\rplfiles\profiles\%3\suboot\system.dat goto HASCLIENTFILES
:DOCOPY
echo Updating client files on %2\rplfiles\profiles\%3 ...
if exist %2\rplfiles\profiles\%3\autoexec.bat del %2\rplfiles\profiles\%3\
autoexec.bat
if exist %2\rplfiles\profiles\%3\config.sys del %2\rplfiles\profiles\%3\
config.sys
mkdir %2\rplfiles\profiles\%3\suboot
if not errorlevel 0 goto COPYERROR
for %%i in (
autoexec.bat
config.sys
msdos.sys
protocol.ini
system.dat
win.bat
) do copy %1\%SUBOOTDIR%\%%i %2\rplfiles\profiles\%3\suboot\%%i
copy %1\%SUBOOTDIR%\*.dos %2\rplfiles\profiles\%3\suboot
if not errorlevel 0 goto COPYERROR
del %2\rplfiles\profiles\%3\suboot\protman.dos
if not errorlevel 0 goto COPYERROR
echo NOTE: Don't forget to edit MACHINES.INI!
goto END
:TOOMANYSUBOOT
echo There are too many SUBOOT subdirectories of the home directory.
echo Please delete the unneeded ones and rename the most current one
echo to %1\suboot.
goto USAGE
:NOSYSTEMDAT
echo The file %1\%SUBOOTDIR%\SYSTEM.DAT could not be found.
echo Check that home directory %1 is correct.
goto USAGE
:NODATA
echo The file %2\RPLFILES\PROFILES\%3\LANMAN.DOS\LANMAN.INI could not be found.
echo Check that server name %2 and profile name %3 are correct.
goto USAGE
:HASCLIENTFILES
echo Client files are already present on %2\rplfiles\profiles\%3.
goto END
:COPYERROR
echo An error occurred copying files.
goto END
:USAGE
echo �
echo Syntax for WIN95CLT:
echo �
echo WIN95CLT [homedir] [rplserver] [profile]
echo �
echo [homedir] = workstation's home directory
echo [rplserver] = remoteboot servername (e.g. \\RPLSERVER)
echo [profile] = name of profile assigned to workstation (e.g. WIN95IP)
echo �
echo Example: WIN95clt g:\homedir1 \\RPLSERVER Win95IP
goto END
:END

You might also like