@REM FILE INSTALL.BAT - This version is for installing RKTOOLS @REM - Modify last part as needed to install other software @echo off echo ============================================================ echo University of Georgia AI Center Software Installation Script echo ============================================================ rem ======================================================================= rem === Setup and Tests =================================================== rem ======================================================================= rem These operations are performed at the beginning of every install.bat rem script in order to support all versions of Windows. rem They supersede an earlier set of tests used before 2007. rem M. Covington 2007 July 25 rem ======================================================================= rem === Verify a sufficiently high version of Windows and enable extensions :test0 echo Checking Windows version... verify other 2>nul setlocal enableextensions if not errorlevel 1 goto :test1 echo. echo This installation script is for XP, 2003, or Vista. echo It will probably work under Windows 2000 but not 95, 98, or ME. echo. echo If you are receiving this message even though you have Windows XP echo or later, another possibility is that command extensions are echo disabled through a registry setting. This is a very rare problem. echo. goto :testfail rem ======================================================================= rem === CD to the correct directory and verify it is not a UNC path :test1 rem In Vista, if install.bat is running elevated, its initial working rem directory will not be where it resides, so set it to be so. rem In earlier versions of Windows this is a null operation. echo Checking install script path... if %~d0==\\ goto :test1b cd /d "%~dp0" if errorlevel 1 goto :test1b rem Note: %cd% does not end with a backslash, %dp0 does. if not "%cd%\"=="%~dp0" goto :test1b goto test2 :test1b echo. echo * This script can't run because of something wrong with its working directory. echo * The most common cause is that its location does not have a drive letter. echo * If you are executing it from a network location, please use echo * "Map Network Drive" to access it with a drive letter, and try again. echo. goto :testfail rem ======================================================================= rem === Verify that the script has sufficient privileges :test2 echo Checking install script privileges... rem Try to do something that is off limits if not elevated privilege rmdir /q "%allusersprofile%\desktop\testpriv" 2>nul mkdir "%allusersprofile%\desktop\testpriv" rmdir /q "%allusersprofile%\desktop\testpriv" 2>nul if not errorlevel 1 goto :testpass echo. echo * This script is not running with sufficient privileges. echo. echo * You must be using an administrator account. The "Owner" echo account or the first account set up on a machine is echo almost always an administrator account. echo. :testuac echo * Under Windows Vista with UAC, you should launch this script echo either by using the separate INSTALL-VISTA script, or by echo right-clicking and choosing Run As Administrator. echo. goto :testfail rem ======================================================================= rem === Tests failed, so bail out :testfail color 0c echo YOUR SOFTWARE WAS NOT INSTALLED. echo Press any key to exit... pause >nul exit rem ======================================================================= rem === Tests passed :testpass color 0b echo Ready to begin installation. echo. rem ======================================================================= rem === Main body of installation script ================================== rem ======================================================================= echo Installing Windows Resource Kit Tools echo. echo This is a free Microsoft toolkit that adds a number of echo command line utilities to Windows XP, 2003, and Vista, echo including ROBOCOPY, DISKMAP, and DIRUSE. echo. echo It is not for Windows 2000. echo. echo We normally install it in the AI Center. echo Whether you install it for home use is entirely up to you, echo since it is not needed for LaTeX, Lisp, or Prolog. echo. echo Under Vista, you may get a warning that there may be echo "compatibility issues." Choose "Run." You will not have problems. echo. echo Press Ctrl-Break to quit, or pause rktools.exe