0% found this document useful (0 votes)
26 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)
26 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

@echo OFF

if "%1"=="" goto USAGE


if "%2"=="" goto USAGE
if "%3"=="" goto USAGE
set SUBOOTDIR=
if exist %1\suboot\[Link] set SUBOOTDIR=suboot
if exist %1\suboot.000\[Link] set SUBOOTDIR=suboot.000
if exist %1\suboot.001\[Link] set SUBOOTDIR=suboot.001
if exist %1\suboot.002\[Link] set SUBOOTDIR=suboot.002
if exist %1\suboot.003\[Link] set SUBOOTDIR=suboot.003
if exist %1\suboot.004\[Link] set SUBOOTDIR=suboot.004
if exist %1\suboot.005\[Link] set SUBOOTDIR=suboot.005
if exist %1\suboot.006\[Link] set SUBOOTDIR=suboot.006
if exist %1\suboot.007\[Link] set SUBOOTDIR=suboot.007
if exist %1\suboot.008\[Link] set SUBOOTDIR=suboot.008
if exist %1\suboot.009\[Link] goto TOOMANYSUBOOT
if "%SUBOOTDIR%"=="" goto NOSYSTEMDAT
if not exist %2\rplfiles\profiles\%3\[Link]\[Link] goto NODATA
if exist %2\rplfiles\profiles\%3\suboot\[Link] goto HASCLIENTFILES
:DOCOPY
echo Updating client files on %2\rplfiles\profiles\%3 ...
if exist %2\rplfiles\profiles\%3\[Link] del %2\rplfiles\profiles\%3\
[Link]
if exist %2\rplfiles\profiles\%3\[Link] del %2\rplfiles\profiles\%3\
[Link]
mkdir %2\rplfiles\profiles\%3\suboot
if not errorlevel 0 goto COPYERROR
for %%i in (
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
) 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\[Link]
if not errorlevel 0 goto COPYERROR
echo NOTE: Don't forget to edit [Link]!
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%\[Link] could not be found.
echo Check that home directory %1 is correct.
goto USAGE
:NODATA
echo The file %2\RPLFILES\PROFILES\%3\[Link]\[Link] 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