anchor.diff:  :::::::::::::::::::::
   :: STAGE 4: Repair :: // Begin jobs
   :::::::::::::::::::::
  -call functions\log_with_date.bat "   stage_4_repair begin..."
  +call functions\log_with_date.bat "  stage_4_repair begin..."
   
   
   :: JOB: MSI installer cleanup
   title Tron v%TRON_VERSION% [stage_4_repair] [MSI installer cleanup]
  -call functions\log_with_date.bat "    Cleaning up orphaned MSI cache files..."
  +call functions\log_with_date.bat "   Cleaning up orphaned MSI cache files..."
   if /i %VERBOSE%==yes (
   	if /i %DRY_RUN%==no stage_4_repair\msi_cleanup\msizap.exe G!
   ) else (
   	if /i %DRY_RUN%==no stage_4_repair\msi_cleanup\msizap.exe G! >> "%LOGPATH%\%LOGFILE%" 2>&1
   )
  -call functions\log_with_date.bat "    Done."
  +call functions\log_with_date.bat "   Done."
   
   
   :: JOB: Check Windows Image for corruptions (Windows 8 and up)
   if %WIN_VER_NUM% geq 6.2 (
   	title Tron v%TRON_VERSION% [stage_4_repair] [DISM Check]
  -	call functions\log_with_date.bat "    Launch job 'DISM Windows image check'..."
  -	if /i %DRY_RUN%==yes goto skip_dism_image_check
  -	Dism /Online /NoRestart /Cleanup-Image /ScanHealth /Logpath:"%RAW_LOGS%\dism_check.log"
  +	
  +	:: Check if we were requested to skip DISM cleanup
  +	if /i %SKIP_DISM_CLEANUP%==yes (
  +		call functions\log_with_date.bat "!  SKIP_DISM_CLEANUP (-sdc) set. Skipping DISM cleanup."
  +		goto skip_dism_cleanup
  +		)
  +	
  +	call functions\log_with_date.bat "   Launch job 'DISM Windows image check'..."
  +	if /i %DRY_RUN%==yes goto skip_dism_cleanup
  +	dism /Online /NoRestart /Cleanup-Image /ScanHealth /Logpath:"%RAW_LOGS%\dism_check.log"
   )
   
   :: If we detect errors try to repair them
   if not %ERRORLEVEL%==0 (
   	title Tron v%TRON_VERSION% [stage_4_repair] [DISM Repair]
   	if %WIN_VER_NUM% geq 6.2 (
  -		call functions\log_with_date.bat " !  DISM: Image corruption detected. Attempting repair..."
  +		call functions\log_with_date.bat "!  DISM: Image corruption detected. Attempting repair..."
   		:: Add /LimitAccess flag to this command to prevent connecting to Windows Update for replacement files
  -		Dism /Online /NoRestart /Cleanup-Image /RestoreHealth /Logpath:"%RAW_LOGS%\dism_repair.log"
  +		dism /Online /NoRestart /Cleanup-Image /RestoreHealth /Logpath:"%RAW_LOGS%\dism_repair.log"
   	)
   ) else (
  -	call functions\log_with_date.bat "    DISM: No image corruption detected."
  +	call functions\log_with_date.bat "   DISM: No image corruption detected."
   )
   
   :: Add the DISM logs to the main Tron log
   if %WIN_VER_NUM% gtr 6.2 (
  -	call functions\log_with_date.bat "    Compiling DISM logs into main Tron log..."
  +	call functions\log_with_date.bat "   Compiling DISM logs into main Tron log..."
   	if exist "%RAW_LOGS%\dism_check.log" type "%RAW_LOGS%\dism_check.log" >> "%LOGPATH%\%LOGFILE%"
   	if exist "%RAW_LOGS%\dism_repair.log" type "%RAW_LOGS%\dism_repair.log" >> "%LOGPATH%\%LOGFILE%"
   )
   
  -:skip_dism_image_check
  -call functions\log_with_date.bat "    Done."
  +:skip_dism_cleanup
  +call functions\log_with_date.bat "   Done."
   
   
   :: JOB: System File Checker (SFC) scan
   title Tron v%TRON_VERSION% [stage_4_repair] [SFC Scan]
  -call functions\log_with_date.bat "    Launch job 'System File Checker'..."
  +call functions\log_with_date.bat "   Launch job 'System File Checker'..."
   if /i %DRY_RUN%==no (
   	REM Basically this says "If OS is NOT XP or 2003, go ahead and run system file checker." We skip SFC on XP/2k3 because it forces a reboot
   	if %WIN_VER_NUM% geq 6.0 (
  
positive.code: 		%SystemRoot%\System32\findstr.exe /c:"[SR]" %SystemRoot%\logs\cbs\cbs.log>> "%LOGPATH%\%LOGFILE%" 2>NUL
  	)
  )
  call functions\log_with_date.bat "    Done."
  
  
  :: JOB: chkdsk the system drive
  title Tron v%TRON_VERSION% [stage_4_repair] [chkdsk]
  call functions\log_with_date.bat "    Launch job 'chkdsk'..."
  call functions\log_with_date.bat "    Checking %SystemDrive% for errors..."
  :: Run a read-only scan and look for errors. Schedule a scan at next reboot if errors found
  if /i %DRY_RUN%==no %SystemRoot%\System32\chkdsk.exe %SystemDrive%
  if /i not %ERRORLEVEL%==0 (
  	call functions\log_with_date.bat " !  Errors found on %SystemDrive%. Scheduling full chkdsk at next reboot."
  	if /i %DRY_RUN%==no fsutil dirty set %SystemDrive%
  ) else (
  	call functions\log_with_date.bat "    No errors found on %SystemDrive%. Skipping full chkdsk at next reboot."
  )
  call functions\log_with_date.bat "    Done."
  
  
  :: JOB: Remove Microsoft telemetry (user tracking)
  title Tron v%TRON_VERSION% [stage_4_repair] [disable MS telemetry]
  if /i %SKIP_TELEMETRY_REMOVAL%==yes (
  	call functions\log_with_date.bat " !  SKIP_TELEMETRY_REMOVAL (-str) set. Disabling instead of removing."
  	REM Only disable telemetry, don't completely purge it
  	if %VERBOSE%==yes (
  		REM GPO options to disable telemetry
  
negative.code: :: Requirements:  1. Administrator access
  ::                2. Safe mode is recommended but not required
  :: Author:        vocatus on reddit.com/r/TronScript ( vocatus.gate at gmail ) // PGP key: 0x07d1490f82a211a2
  :: Version:       1.2.4 ! Fix bug where DISM cleanup wasn't skipped even if the -sdc switch was used. Thanks to u/HittingSmoke
  ::                1.2.3 * Update date/time logging functions to use new log_with_date.bat. Thanks to /u/DudeManFoo
  ::                1.2.2 * script: Update script to support standalone execution
  ::                1.2.1 + Add job 'Disable NVIDIA telemetry.' Thanks /u/TootZoot
  ::                1.2.0 - Remove job "Reset Filesystem permissions" and associated files
  