Critical compatibility fixes - DOS 6.22 does not support many Windows batch file features. Removed all incompatible commands and replaced with DOS 6.22 compatible alternatives. Issues Fixed: 1. DEPLOY.BAT - Removed SET /P (interactive input) - Changed from: SET /P MACHINE=Machine name: - Changed to: SET MACHINE=%1 (command-line parameter) - Usage: DEPLOY.BAT TS-4R - DOS 6.22 does not support SET /P 2. CHECKUPD.BAT - Removed SET /A (arithmetic) and GOTO :EOF - Removed 6 instances of SET /A counter arithmetic - Replaced numeric counters with flag variables - Changed from: SET /A COMMON=COMMON+1 - Changed to: SET COMMON=FOUND - Replaced GOTO :EOF with actual labels - Changed display from counts to status messages 3. STAGE.BAT - Removed FOR /F (file parsing) - Changed from: FOR /F "skip=1 delims=" %%L IN (...) DO - Changed to: TYPE C:\AUTOEXEC.BAT >> C:\AUTOEXEC.TMP - DOS 6.22 only supports simple FOR loops Created check-dos-compatibility.ps1: - Automated scanner for DOS 6.22 incompatible commands - Checks for: SET /P, SET /A, IF /I, FOR /F, FOR /L, FOR /R, GOTO :EOF, %COMPUTERNAME%, &&, ||, START, invalid NUL usage - Scans all BAT files and reports line numbers - Essential for preventing future compatibility issues Verification: - All files maintain CRLF line terminators - All commands tested for DOS 6.22 compatibility - No SET /A, SET /P, FOR /F, GOTO :EOF remaining - CHOICE commands retained (CHOICE.COM exists in DOS 6.22) Impact: - DEPLOY.BAT now requires parameter: DEPLOY.BAT TS-4R - CHECKUPD.BAT shows "Updates available" vs exact counts - STAGE.BAT copies all AUTOEXEC lines (duplicate @ECHO OFF harmless) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
3.0 KiB
3.0 KiB