anchor.diff:  :#----------------------------------------------------------------------------#
   
   :IsAdmin
  ->NUL 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system"
  -exit /b
  +setlocal EnableExtensions DisableDelayedExpansion
  +
  +set "CONFIG_DIR=%SYSTEMROOT%\system32\config"
  +:# In 32-bits cmd shells in 64-bits Window, the config directory is in the native system32
  +if defined PROCESSOR_ARCHITEW6432 set "CONFIG_DIR=%SYSTEMROOT%\sysnative\config"
  +
  +>NUL 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%CONFIG_DIR%\system"
  +endlocal & exit /b
   
   :#----------------------------------------------------------------------------#
   
  
positive.code: :#  Filename        setup.bat			                              #
  :#                                                                            #
  :#  Description     Install or upgrade ag.exe				      #
  :#                                                                            #
  :#  Notes 	                                                              #
  :#                                                                            #
  
negative.code: %UNINSTALL_CMD%
  if errorlevel 1 (
    %ERROR% The Silver Searcher uninstallation failed
    %PAUSE%
    endlocal & %RETURN% 1
  )
  %COMMENT% The Silver Searcher was uninstalled successfully
  