anchor.diff:  
   
   :: PREP: Detect Solid State hard drives or Virtual Machine installation (determines if post-run defrag executes or not)
  -:: Basically we use a trick to set the global SSD_DETECTED variable outside of the setlocal block by stacking it on the same line so it gets executed along with ENDLOCAL
  -set SSD_DETECTED=no
  +:: Basically we use a trick to set the global SKIP_DEFRAG variable outside of the setlocal block by stacking it on the same line so it gets executed along with ENDLOCAL
   SETLOCAL ENABLEDELAYEDEXPANSION
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "Solid State" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_ssd&& goto freespace_check
   	)
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "SSD" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_ssd&& goto freespace_check
   	)
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "RAID" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_ssd&& goto freespace_check
   	)
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "SandForce" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_ssd&& goto freespace_check
   	)
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "VMware" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_vm&& goto freespace_check
   	)
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "VBOX" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_vm&& goto freespace_check
   	)
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "XENSRC" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_vm&& goto freespace_check
   	)
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "PVDISK" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  -	)
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_vm&& goto freespace_check
  +	)
  +:: Failsafe for drives that can't be read. Re: issue #59 on GitHub
   for /f "tokens=1" %%i in ('stage_6_optimize\defrag\smartctl.exe --scan') do (
  -	:: Failsafe for drives that can't be read. Re: issue #59 on GitHub
   	stage_6_optimize\defrag\smartctl.exe %%i -a | %FIND% /i "Read Device Identity Failed" >NUL
  -	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SSD_DETECTED=yes&& goto freespace_check
  +	if "!ERRORLEVEL!"=="0" ENDLOCAL DISABLEDELAYEDEXPANSION && set SKIP_DEFRAG=yes_error&& goto freespace_check
   	)
   ENDLOCAL DISABLEDELAYEDEXPANSION
   
  
positive.code: :: Author:        vocatus on reddit.com/r/TronScript ( vocatus.gate at gmail ) // PGP key: 0x07d1490f82a211a2
  :: Version:       8.4.0 + tron.bat:prep:          Add new -sdc switch and associated SKIP_DISM_CLEANUP variable. Use this to skip DISM component (SxS store) cleanup. Thanks to /u/silentchasm
  ::                      + tron.bat:ssd_detection: Add virtual disk detection. If found, skip Stage 5 defrag. Thanks to /u/fezzgig
  ::
  :: Usage:         Run this script in Safe Mode as an Administrator, follow the prompts, and reboot when finished. That's it.
  ::
  
negative.code: 	echo    HELP:                   %HELP%
  	echo    SAFE_MODE:              %SAFE_MODE%
  	echo    SAFEBOOT_OPTION:        %SAFEBOOT_OPTION%
  	echo    TEMP:                   !TEMP!
  	echo    TIME:                   %TIME%
  	echo    PROCESSOR_ARCHITECTURE: %PROCESSOR_ARCHITECTURE%
  